[TYPO3-english] Hi, a question about bug - 0008343: improved 404 pagenotfound_handling not working for certain requested URLs/resources
Christopher Torgalson
bedlamhotel at gmail.com
Tue Feb 16 03:41:23 CET 2010
Hi,
On Mon, Feb 15, 2010 at 6:03 PM, Matthew K - (Swagman Solutions)
<typo3 at swagmansolutions.com.au> wrote:
> Hi All,
>
> How can I have this bug assigned, reviewed and repaired which has was
> reported back in May 2008.
>
> This bug relates to the way in which the the typo3 core handles '404 error
> handling', which at the moment fails to handle 404 errors correctly.
>
>
> Following here is the description in detail from
> http://bugs.typo3.org/view.php?id=8343 which also has details & code
> suggestions with potential 'how to fix':
>
> ----------------------------------------------------------------------------------------
>
> When using default TYPO3 .htaccess file and with or without 'simulate static
> documents' it appears that 404 pagenotfound_handling works only for
> requested files:
>
> - that have .html as the file suffix
> - and the file being called is requested from the root of a
> typo3 site, i.e. www.domain.com.au/file.html
>
> If 'file.html' exists, page is shown
>
> If 'wrongfile.html' does not exist then correct 404 handling takes place
> correctly, due to function '$this->checkAndSetAlias()'
>
> The '404 pagenotfound_handling' feature fails to show the 404 headers for
> the following requested resources:
>
> - www.domain.com.au/file.htm
> - www.domain.com.au/file.pdf
>
> - www.domain.com.au/folder/
> - www.domain.com.au/folder/file.html
> - www.domain.com.au/folder/file.pdf
>
> When the above requested resources fail, the browser is given a 200 OK http
> header and is shown the home page of the website with the requested
> resources URL remaining in the browsers address bar. This could be due to
> $this->id being 'false' and then $this->id is set to '0' in function
> 'setIDfromArgV()'.
>
> My suggested code to patch class.tslib_fe.php works on the premise that
> $this->TYPO3_CONF_VARS['FE']['pageNotFound_handling'] value is TRUE, but
> perhaps the TYPO3 404 handling should still work when
> $this->TYPO3_CONF_VARS['FE']['pageNotFound_handling'] is FALSE and therefore
> still show 404 headers and redirect to home page/ root page of website.
>
> ----------------------------------------------------------------------------------------
>
> Any thoughts greatly appreciated with regards to this matter.
Well, you could always sponsor the fix (I know, you've submitted a
patch already, I'm only kidding) :)
I just wanted to clarify for other readers: the bug as reported
affects (or did when I checked close to two years ago) non-Realurl
TYPO3 installations with or without simulateStaticDocuments enabled.
This means links like /index.php?id=32&type=0 and links like 32.0.html
both seemed to be affected. For details, refer to the original mailing
list thread [1].
[1] http://typo3.toaster-schwerin.de/typo3_dev/2008_05/threads.html#00116
--
Christopher Torgalson
http://www.typo3apprentice.com/
More information about the TYPO3-english
mailing list