Project

General

Profile

Actions

Bug #16167

closed

pageNotFound_handling returns 301 instead of 404 as status code

Added by Dmitry Dulepov over 18 years ago. Updated over 18 years ago.

Status:
Closed
Priority:
Should have
Category:
Communication
Target version:
-
Start date:
2006-05-22
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.0
PHP Version:
4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Problem: if $TYPO3_CONF_VARS['FE']['pageNotFound_handling'] is set to
absolute or relative URL, than
$TYPO3_CONF_VARS['FE']['pageNotFound_handling_statheader'] is ignored
and client is redirected to error page using code 302. This is
especially bad for search engines like Google because (1) they may not
remove such pages from their index (2) sitemaps do not work properly.

Solution: use t3lib_div::getURL() to fetch error page internally and
pass it to client with correct header. getURL() is extended to accept
custom HTTP headers that we need to send to 404 page (referrer and user
agent).

Patch was discussed in the "core" list and Martin Kutschker voted for it. So only one "+1" is missing. Patch is attached.

(issue imported from #M3532)


Files

404_v2.txt (7.42 KB) 404_v2.txt Administrator Admin, 2006-05-22 14:48
404_v3a.txt (12.7 KB) 404_v3a.txt Administrator Admin, 2006-07-10 12:11
404_v3c.txt (7.07 KB) 404_v3c.txt Administrator Admin, 2006-07-10 12:19
404_final.txt (7.12 KB) 404_final.txt Administrator Admin, 2006-07-11 23:16

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #20772: pageNotFound_handling returns 301 instead of 404Closed2009-07-20

Actions
Actions

Also available in: Atom PDF