proxy pac file
Using WIndows 7 Pro SP1 i made a notepad file with the following text:
{
if (isInNet(myIpAddress(), "192.0.0.0", "255.255.0.0"))
return "PROXY 120.16.2.30:8080; DIRECT";
else return "DIRECT";
}
My own ip adress is at work lets say: 192.0.10.100 in a 255.255.0.0 subnet. When i am not at work the ipadress changes off course. I have been testing let IE start with the configuration script proxy.pac in
file://c:/windows/system32
IE is not working at home nor at work.
What am i doiing wrong, my ip is in the range so when ip is 192.0.10.100 proxy must be used and when another range noting must be used.. directly Internet.
freddie
April 26th, 2012 9:26am
Hi,
Have a try with the following settings.
if (isInNet(myIpAddress(), "192.0.0.0", "255.255.0.0"))
return "DIRECT";
else return "DIRECT";
Another suggestion is to replace other proxy servers for testing.
Here is a related guide can be referred to.
FindProxyForURL.COM - A Proxy Auto-Configuration Resource
http://www.findproxyforurl.com/pac_functions_explained.html
If you have further question about this issue, please let me know.Ivan-Liu
TechNet Community Support
Free Windows Admin Tool Kit Click here and download it now
April 27th, 2012 5:24am
Ivan,
Thx. But when i do:
if (isInNet(myIpAddress(), "192.0.0.0", "255.255.0.0"))
return "DIRECT";
else return "DIRECT";
whatever situation i am in at work or somewhere else IE is always goiiing to try Internet directly without proxy server...
I would not prefer to use findproxy because i have done that and it takes about a minute before IE knows it cannot reach te proxyserver and goes directly. This is much to long. So i thought when i let IE know that if my ip is in a LAN then go thru proxy
else go directly..
freddie
April 29th, 2012 9:25am
Have a try with "192.0.10.0","255.255.255.0"Ivan-Liu
TechNet Community Support
Free Windows Admin Tool Kit Click here and download it now
May 4th, 2012 4:29am