How to: Return a 404 header!

16 years 8 months ago #44387 by jeffason
How to: Return a 404 header! was created by jeffason
Hello!

I have SEO going where people can use www.domain.com/username to get to a page. The only problem is that any invalid url will get picked up by this well, but will just return "no profile found"

What I need is for joomla to instead return the 404 headers of page not found.

How is this possible?

edit comprofiler.php

and insert the header part in the following area of code:


[code:1]if (count($users)==0) {

echo _UE_NOSUCHPROFILE;
header("HTTP/1.0 404 Not Found"«»);
return;

}
[/code:1]

Post edited by: jeffason, at: 2007/08/29 22:36

Post edited by: jeffason, at: 2007/08/29 22:38

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.150 seconds

Facebook Twitter LinkedIn