#25135 [NEW]: Strange redirection issue on missing page
| From: | kraj at illumen dot com | Date: | Mon, 18 Aug 2003 23:01:05 +0000 |
| Subject: | #25135 [NEW]: Strange redirection issue on missing page | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-46137@lists.php.net to get a copy of this message | ||
From: kraj at illumen dot com
Operating system: FreeBSD 4.8
PHP version: 4.3.3RC4
PHP Bug Type: Apache related
Bug description: Strange redirection issue on missing page
Description:
------------
OS - FreeBSD 4.8
PHP Version 4.3.3 RC2
Apache 1.3.28
We migrated a website which was totally static html to a new php site.
The search engines still point to pages on the old website.
The old website had a directory structure breaking up the site into
sections. The new website has a php script for each section.
As an example, the old website had a page access via the following URL:
http://www.icetips.com/sql/mysqlpageloading.htm
If one tries to link to this page, instead of the document not found page
which is normally issued, the engine is running the script called sql.php
located on the document root, but none of the links work because it
believes that the base for the relative URL's is
http://www.icetips.com/sql/
THe proper behavior should be to display the ErrorDocument.
I am not sure if this is a problem caused by Apache or by PHP. If I try
to retrieve a page with a directory for which there is no php script with
the name (less the extension) which is the same as the bogus directory
then we are being redirected to the ErrorDocument properly.
For example:
http://www.icetips.com/whatever/whenever.html
Could not test with either RC3 or RC4 because the ports collection does
not have those sources available at this time.
Reproduce code:
---------------
Access URL
http://www.icetips.com/sql/mysqlpageloading.htm
result in script
http://www.icetips.com/sql.php
being executed
Expected result:
----------------
Should display the ErrorDocument
Actual result:
--------------
Displays http://www.icetips.com/sql.php setting base
directory to
http://www.icetips.com/sql/
--
Edit bug report at http://bugs.php.net/?id=25135&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25135&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25135&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=25135&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=25135&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=25135&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=25135&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=25135&r=support
Expected behavior: http://bugs.php.net/fix.php?id=25135&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=25135&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=25135&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=25135&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25135&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=25135&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=25135&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=25135&r=gnused