redirect man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

redirect(8)							   redirect(8)

NAME
       redirect - simple redirection CGI program

SYNOPSIS
       redirect

DESCRIPTION
       Three steps to set up a redirection:

       1. Make sure your web server is set up to allow CGI programs.

       2.  Make	 a  symbolic link from the file or directory you want to redi‐
       rect, pointing at this program in the CGI bin directory.

       3. Add an entry to the file ".redirects" in the	directory  where  your
       http server runs CGI programs.  For most servers, this is the directory
       where the given CGI program lives.  The format of the file is  a	 bunch
       of lines with a filename, whitespace, and the new URL.  For example:
	 /test/oldfile.html    http://www.acme.com/test/newfile.html
       The  easiest  way  to  figure  out  precisely what filename to put into
       .redirects is to set up the symlink and then click on it.   You'll  get
       back  a "404 Not Found" page which includes the filename as received by
       the redirect program, and that's what you want to use.

       You can also add a wildcard specification to redirect whole  groups  of
       files.  For example:
	 /wildtest/*	      http://www.acme.com/test-
       will cause an access to the /wildtest/somefile.html to be redirected to
       http://www.acme.com/test-somefile.html. (Note that  the	asterisk  need
       not be preceded by a slash.)

       Note:   this   is   designed   for   thttpd  (http://www.acme.com/soft‐
       ware/thttpd/) and using it with other  web  servers  may	 require  some
       hacking.	 A possible gotcha is with the symbolic link from the old file
       pointing at this script - servers other than thttpd may not allow  that
       link  to	 be run as a CGI program, because they don't check the link to
       see that it points into the allowed CGI directory.

SEE ALSO
       thttpd(8)

BUGS / DEFICIENCIES
       It would be really cool to have this program look  for  the  .redirects
       file  in the same directory as the file being redirected, instead of in
       the binaries directory.	Unfortunately, this appears to	be  impossible
       with  the  information  CGI  gives, plus the non-standardized but wide‐
       spread practice of running CGI programs	in  the	 directory  where  the
       binary lives.  Perhaps CGI 1.2 will address this.

       The  wildcard  mechanism is very primitive.  In particular, any charac‐
       ters that follow the asterisk are blithely ignored.

AUTHOR
       Copyright � 1995 by  Jef	 Poskanzer  <jef@mail.acme.com>.   All	rights
       reserved.

			       23 September 1995		   redirect(8)
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net