[TYPO3-english] Custom 404 with 404 header and CoolURI?
Axel Joensson
a.joensson at web.de
Thu Oct 28 01:35:38 CEST 2010
Christopher Torgalson <bedlamhotel at gmail.com> wrote:
> Well, you'll need a CoolURI expert I suppose. But the above
> configuration works correctly with RealURL.
Maybe, but that is not installed in the respective domain.
I have in fact just found a rather bizzare "solution". In the
CoolUriConf.xml, the section dealing with 404s by standard looks like
this:
<pagenotfound>
<status>HTTP/1.0 404 Not Found</status>
<behavior type="message"><![CDATA[ <h1>Page not found!</h1>
]]></behavior>
</pagenotfound>
This option behaves correctly in terms of issueing a 404, the included
CDATA and nothing else. Other options are to define a <behavior
type="redirect">, where a page inside the T3 tree can be defined, but
which does not send a 404, but a 302; or to take <...type="page">, which
also does not send 404, as far as I can see.
The slightly absurd solution is to use the "message" type first
mentioned, but to paste the complete static HTML code of the desired
page into the CDATA part, instead of the message defined by standard.
That "works", as the desired page completely appears, without changing
the wrong URI entered AND it sends a correct 404. However, it pumps up
the config, in my case, from 1,9 to 4,7 kB and it feels like slowing
down the complete site. Is that impression true or just coming from my
tired eyes? Anyone with another idea?
Regards
More information about the TYPO3-english
mailing list