prevent a page from being picked up by a search engine

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
noguru
Forum Commoner
Posts: 61
Joined: Thu Jun 06, 2002 4:03 am
Location: Just north of the City Of Gold, Land of Milk and Honey

prevent a page from being picked up by a search engine

Post by noguru »

Is there a way to prevent a webpage from being picked up by 'n search engine? I used frames and now google is not only picking up the default page (which contains the framesets), but also the page in the main frame. When this page is loaded, the functionality in the other frames is lost. I need only the default page to be picked up by search engines.
dusty
Forum Contributor
Posts: 122
Joined: Sun Apr 28, 2002 9:52 pm
Location: Portsmouth, VA

Post by dusty »

<META NAME="ROBOTS" CONTENT="NOINDEX">
User avatar
noguru
Forum Commoner
Posts: 61
Joined: Thu Jun 06, 2002 4:03 am
Location: Just north of the City Of Gold, Land of Milk and Honey

Post by noguru »

i've tried it, but google still picks up my page. does it take a while?

i've managed to write the following piece of client-side script that also does the trick. it checks if the window is a frame and if not, it redirects to the default page:

Code: Select all

<script language="JavaScript">
wn = window.name;
if (wn.length==0) &#123;
window.parent.location.href = 'http://whatever/';
&#125;
</script>
Thanks anyway.
dusty
Forum Contributor
Posts: 122
Joined: Sun Apr 28, 2002 9:52 pm
Location: Portsmouth, VA

Post by dusty »

google has to reindex your site for the changes to take place i believe. some search engines are manual and you have to login and do it yourself.
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

Search on google for "robots.txt". Theres a few codes you can do to that file to block the search engine for looking over certain files, folders. This is especially good for /admin or /beta /test folders.
Image Image
Post Reply