![]() |
|
|
|
||||||||||
![]() |
|
|
Thread Tools |
|
#1
|
||||
|
||||
|
Trying to verify a Google sitemap I get an error message like this:
Google gives me this message and explanation when I try to verify a Sitemap:
Quote:
Is it all about mod-rewriting in my .htaccess file? If it is about mod-rewriting, do anyone here have any idea what to write? Incidentally Google seems to be indexing (all my pages more or less) and then de-indexing quite a lot on a daily basis... I wonder what that is all about? |
|
#2
|
||||
|
||||
|
You probably have custom 404 pages, right?
Maybe you redirect 404's to a standard page? Basically, the issue is your 404s throw up a 200 status, not a 404. If you are not familiar with those things then it must have been something your host has kindly set up, but wrongly so! Contact them I'd say.
__________________
Try: Sell Your Ad Space - Thousands Of Visitors Want To Buy Your Ad Space Global Internet Index Directory <- Check it out! -> |
|
#3
|
||||
|
||||
|
It's about http status codes, and what your server is returning when a page is not found.
200 OK means the file was found 404 Not Found means the file doesn't exist These are status codes sent in the http header, and you can't see them directly. You either need to use ethereal to sniff and watch, or look in the access_log of the web server, where you'll see them logged for each request sent to the server. So what G is doing is having you place a file on your server with a unique name, and then they access it [using HEAD and not GET] to see if it exists. The server should return a 200 Ok. Then G requests a random made up name like "test_404_response_page_ahas9a0aa01ajHasn", which should return a 404 Not Found. If the GoogleBot receives a 200 Ok then it means that the server always returns a 200 Ok, regardless of whether the file is there or not, and so G can't actually verify the file exists [i.e. the server always says the file exists no matter what]. If you have a custom 404 page that says 'sorry page not found' and it's not sending a 404, and you have php installed add to the top of the custom 404 page: <?php header('HTTP/1.0 404 Not Found'); ?> |
|
#4
|
||||
|
||||
|
Quote:
My wordpres theme does not have a 404 page, but an post loop on the index page, if no page match - then message = "Sorry, no posts". I tried to make an include to 404.php, but that inserts the 404 page in the index (not good because now I get a header error with your php header inserted in the middle of the body). I need a php command to move to 404.php (I'm a php novice still) - How do I do this? |
|
#5
|
||||
|
||||
|
Look at this page on your site: www.coffeecoffee.be/404_qwerty
Find out why that's showing up. It's not a Wordpress issue. Your server is configured to render that page when a page isn't found. Once you know that and fix it, the 404's should get returned. |
|
#6
|
||||
|
||||
|
Update:
I am now trying this: Quote:
I guess it is because I put the contents of the 404.php page (including the "<?php header("HTTP/1.1 404 Not Found"); ?>" sentence) in the body of the page, which obviously is wrong, but I cannot figure out how to clear the page so the header is being red as a header - if you understand what I mean? It's close to midnight here, I'm deep in php books that used to be unopened, and I am not resting until this is working. Any help is truly appreciated. |
|
#7
|
||||
|
||||
|
Rather than looking in the php code I'd check the underlying issue of your server doing this. Though there is a chance that it is the application (WP) that has some application top functionalilty that creates those pages.
If you want to stick with the php fix then do a header 301 redirect to that 404 page so you'll end up eventually with the correct 404 header.
__________________
Try: Sell Your Ad Space - Thousands Of Visitors Want To Buy Your Ad Space Global Internet Index Directory <- Check it out! -> |
|
#8
|
||||
|
||||
|
Quote:
). Meanwhile... This is my source for any non existing URI, showing how the code described earlier results in a 404.php page showing up in the main text area of the body of the index file. I basically want to use php to get rid of all the stuff I made blue so that the header can be read again (I'm propably not making a lot of sense any more but please bear with me). Quote:
|
|
#9
|
||||
|
||||
|
I agree with TOPS30, I don't think it's wordpress, and believe it's your webserver setup. As TOPS30 said in the first recommendation, contact the hosting company and tell them to turn off the 404 handler. Do it in the morning with a fresh start.
|
|
#10
|
||||
|
||||
|
Ok I investigated a bit further.
My host has a 404.html page for all pages. I should mention that I am on a subdomain with http://www.coffeecoffee.be/ pointing to it. On other subdomains I go straight to hosts 404.html page, but on this one with wordpress installed (with permalinks and all), I initially got the wordpress template index page with a post loop telling me "sorry, no posts" if I made a 404_qwerty. Now I'm thinking to try and make something like this in the top of the template index file: Quote:
I strongly believe that I'm a schmuck at php and that it could be rather easy to make the script send the user to my 404.php page if there are no posts, and to run through the normal index header, body and all if there are.Going to bed now (it's 02:45 am and I have got the kids in the morning). I am Going to check up on this first thing in the morning though. |
|
#11
|
||||
|
||||
|
If you are just trying to process the G sitemap verification, just rename the .htaccess, verify then rename it back (or simply turn the rewriting off)
|
|
#12
|
||||
|
||||
|
Actually I went over to the php section of dp and got the answer I needed.
See this thread for a working solution: http://forums.digitalpoint.com/showthread.php?t=50963 |
|
#13
|
|||
|
|||
|
is there a way to make the 404 redirect to the index?
|
|
#14
|
||||
|
||||
|
i think it got something to do with ur htaccess me too having the same problem with my japanese av blog
|
|
#15
|
||||
|
||||
|
Is present an approach in the direction of making the 404 forward toward the index ?
|
|
#16
|
||||
|
||||
|
I had this problem too. Thanks for the advice
__________________
Turbine Legend |
|
#17
|
||||
|
||||
|
200's means a file found and 400's means a file not found..
And now a file found on a file not found. Interesting. Never came across such errors. |
|
#18
|
|||
|
|||
|
404.php file
<?php get_header(); ?> your message here <?php get_sidebar(); ?> <?php get_footer(); ?> |
![]() |
| Bookmarks |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Parsing Error on Google sitemap | Windows-Update-Advisor | Google Sitemaps | 0 | Nov 30th 2005 5:19 am |
| When I verify my bank account, there is a error. please help me! | t10host | Payments | 4 | Nov 23rd 2005 1:33 am |
| google sitemap - Validation error 200 in the header of 404 pages | Fishing Forum | Google Sitemaps | 3 | Nov 8th 2005 10:37 pm |
| Sitemap failed to verify my site ?????? | obrusoft | Google Sitemaps | 2 | Oct 8th 2005 7:29 am |
| error message | fryman | Setup / Validation Help | 3 | Jun 16th 2005 9:23 am |