Exec /cgi-bin/* /usr/local/httpd/cgi-bin/*
Map /* /cgi-bin/redirect/*
The /usr/local/httpd/cgi-bin/redirect script would look like
#!/bin/ksh
case "$REMOTE_HOST" in
*.au | *.nz | *.jp | *.kr )
url="http://Bond.edu.au/External/Misc/apache${PATH_INFO}"
;;
*.at | *.de | *.dk )
url="http://iuinfo.tuwien.ac.at/apache${PATH_INFO}"
;;
* )
url="http://sunsite.doc.ic.ac.uk/packages/apache${PATH_INFO}"
;;
esac
print "$Location: $url"
print "Content-Type: text/html"
print
print "<HTML><HEAD><TITLE>Redirect</TITLE></HEAD><BODY>"
print "<A HREF=\"$url\">Click here!</A>"
print "</BODY></HTML>"
-- Michael Niksch TEL: +41-1-7248-913 IBM Zurich Research Laboratory FAX: +41-1-7240904 Saeumerstrasse 4 nik@zurich.ibm.com (NIK at ZURICH) CH-8803 Rueschlikon / Switzerland http://www.zurich.ibm.com/~nik/