Re: cvs: pearweb /include pear-prepend.php /public_html/error 404.php
| From: | Martin Jansen | Date: | Mon, 03 Jun 2002 06:20:48 +0000 |
| Subject: | Re: cvs: pearweb /include pear-prepend.php /public_html/error 404.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-4384@lists.php.net to get a copy of this message | ||
On Mon, 03 Jun 2002 00:40:57 -0000, Richard Heyes wrote:
>richard Sun Jun 2 20:40:57 2002 EDT
>
> Modified files:
> /pearweb/include pear-prepend.php
> /pearweb/public_html/error 404.php
> Log:
> * Added auto redirection for urls like:
> http://pear.php.net/Mail_Mime
> to package info page. If multiple results shows three results and a
> link to the search page if more than three.
>[...]
>+function redirect($url)
>+{
>+ header('Location: ' . getURL($url));
>+ exit;
>+}
> ?>
Have a look at pearweb/include/pear-format-html.php. There is a
function localRedirect(), which should do the same than your function.
>Index: pearweb/public_html/error/404.php
>diff -u pearweb/public_html/error/404.php:1.1 pearweb/public_html/error/404.php:1.2
>--- pearweb/public_html/error/404.php:1.1 Fri Dec 28 06:55:53 2001
>+++ pearweb/public_html/error/404.php Sun Jun 2 20:40:57 2002
>@@ -1,9 +1,56 @@
>-<?php response_header("Error 404"); ?>
>+<?php
>+/**
>+* Filename.......: 404.php
>+* Project........: Pearweb
>+* Last Modified..: $Date: 2002/06/03 00:40:57 $
>+* CVS Revision...: $Revision: 1.2 $
Uhm, do we really need this? Actually it should be enough to have a
short description what the file does and a line for the cvs id, like:
/**
* $Id$
*
* On 404 error this will search for a package with the same
* name as the requested document. Thus enabling urls such as:
*
* http://pear.php.net/Mail_Mime
*/
>+*
>+* On 404 error this will search for a package with the same
>+* name as the requested document. Thus enabling urls such as:
>+*
>+* http://pear.php.net/Mail_Mime
>+*/
That's what pearweb/public_html/go has been created for, which works
parallel to pearweb/public_html/get (Actually it never got used, but
that's another story :). Please ask on pear-dev or on
pear-webmaster@lists.php.net in the future to avoid such double work.
- Martin