Is Index file necessary in each website? If yes, then how we can hide it from the from the web searcher?
But i think robots.txt used for the crawler and not for the user point of view. How we can hide index file from user with robots.txt
I don't want to remove my home page. I try to tell my question with an example. Suppose a website open with 'abc.com' and its also open with 'abc.com/index.php' so now what can i do so the user not able to open /index.php and crawler also treated that index file as 'abc.com' and not consider it as the different page with duplicate content.
Redirect 301 /index.php / Code (markup): Or add this in your index.php: if($_SERVER['REQUEST_URI']=='/index.php')header('Location: /'); PHP: