View Single Post
  #1  
Old 02-28-2013, 03:23 AM
 
DavyMac DavyMac is offline
 

eXpert
  
Join Date: Apr 2007
Location: Poole, UK
Posts: 333
 

Default Server Response 404 NOT returned for unavailable pages

Using the HTTP Status code checker at SEO Book I discovered that for non-existent html files ( www.mydomain.com/xxxx.html) and folders (www.mydomain.com/xxxx/) instead of X-Cart returning a soft 404 error it is in fact returning "SERVER RESPONSE: HTTP/1.1 200 OK".

In my .htaccess files I have the following:
HTML Code:
# If you would like X-Cart to show informative message for errors caused # by opening of missing/deleted files (HTTP Error 404), please uncomment # the line below. ErrorDocument 404 /404.php # Show default error document for 404 errors caused by opening of image/media files. <Files ~ "\.(gif|jpe?g|png|js|css|swf|ico)$"> ErrorDocument 404 default </Files>

I also have CDSEO Pro set up to display a custom static page when there is a request for a non-existent file. The static page is displayed correctly but server response 200 is returned, which is not correct and in fact damaging.

Missing .php files result in X-Cart's 404 page being displayed.
__________________
X-Cart GOLD Plus v4.5.4
CDSEO Pro
ewdhosting Dedicated Server
Dedicated SSL
Stone Edge OM
Reply With Quote