Forum Moderators: Robert Charlton & goodroi
[edited by: goodroi at 1:31 pm (utc) on Nov 22, 2016]
[edit reason] Welcome to WebmasterWorld, please go read & follow the forum charter :) [/edit]
IF the request is for the home page
AND the referrer is google
RESPOND with 404 Not Found
How it could possible that website is hacked, only the home page is issue is there, all the inner pages are opening from Google search. If it was hacked that whole website wouldn't open from google search. What i will do is I need to check 404 for this website....Irshad, there are a huge number of variations that hackers will use to hijack a site, and the uses they will then make of the site (or the page), but basic to most of them is that the results are cloaked for Googlebot, so the cause of the problem won't be visible to the site owner.
Maybe inner pages were not ranking well enough and home page was the one that bothered someone... who knows.
But it is very easy to put the following in .htaccess or in a script on the server that responds to your request:
IF the request is for the home page
AND the referrer is google
RESPOND with 404 Not Found