We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

Script to add to Trusted Sites

Medium Priority
2,113 Views
Last Modified: 2013-12-08
I have a new portal site I am developing.  
For the TSWEB app to work the site needs to be in the users trusted sites.

I am looking for a code example that I could use to have the users select a link and ask confirmation if they realy want to add it to the trusted sites.

Thanks in advance.

Comment
Watch Question

CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2011

Commented:
If this is needed, can you not simply deploy the IE settings via GPO?

Author

Commented:
This is going to be for remote users to access.  If it were just for the users company  machines that would be an option, but we do not know where the users may try to connect from.
CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2011
Commented:
Both of these commands work from DOS, which means you can incorporate it into a VBScript based on the syntax of the commands, you can put it into a .reg file or use it in a batch file....

Now, it is a batch file..... Notive the DWORD value, either http or https, indicating whether it requires the checkbox....


@echo off
reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\YourSite.com\www" /v https /t reg_dword /d 00000002
 
reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Interne
t Settings\ZoneMap\Domains\YourSite.com\www" /v http /t reg_dword /d 00000002
 
exit

Open in new window

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2011

Commented:
.Registry File.....
Windows Registry Editor Version 5.00
 
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\yoursite.com\www]
"https"=dword:00000002
 
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\yoursite.com\www]
"http"=dword:00000002

Open in new window

Author

Commented:
I actualy just created a vb script that I have called from a link.  I was hoping for something a little cleaner, but this works.
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.