August 7, 2003

Dominique’s birthday

August 7, 2003 - Categories: !Uncategorized

Dominique’s birthday’s on December 27.

Oops, forgot my keys

August 7, 2003 - Categories: !Uncategorized

Forgot my keys again today. I guess I’m going home later…

e-learning conference tomorrow

August 7, 2003 - Categories: !Uncategorized

Manila Hotel

then rush back to school

Automatically detecting proxy settings

August 7, 2003 - Categories: geek


Having gotten sufficiently annoyed at the need to maintain two Mozilla
Firebird profiles just because I use a proxy in school and none at
home, I decided to look up the “Automatically detect proxy
configuration” option. After some digging around, this is the answer I found:

This goes into my /etc/laptop-net/profiles/school/files.d/var/www/proxy.js:

function FindProxyForURL(url,host)
{ if(isPlainHostName(host)||
    isInNet(host,"10.0.0.0","255.0.0.0")) return "DIRECT";
      else return "PROXY proxy.admu.edu.ph:3128; DIRECT";
}

and this goes into my /etc/laptop-net/profiles/home/files.d/var/www/proxy.js:

function FindProxyForURL(url,host)
{
  return "DIRECT";
}

I deleted the other profile and changed my settings to automatically
detect the proxy configuration from file:///var/www/proxy.js .
Tada! No more worries. It just works.