Forum Moderators: open

Message Too Old, No Replies

Open frame page from search results

open frame page from search results

         

rastos

9:45 am on Mar 25, 2003 (gmt 0)



Hi,

I created web page consisting from couple of frames (one frame is menu, second frame is soem picture banner etc.). If somebody tries to use Google then to find my page, he/she is successful. Google shows reference on one XX.htm page which is used in one of the frames normally. If user will click on XX.htm reference link then XX.htm is showed in the whole browser window and I do not see for example menu which was normally in one frame. Said in short I see just XX.htm web page in the browser window.

This is quite expected but PROBLEM IS that I would like to show to people the frame page if somebody will click on link found by some search engine. How can I solve it?

Thanks in advance

universalis

2:13 pm on Mar 25, 2003 (gmt 0)

10+ Year Member



Try adapting this bit of javascript on the head section of XX.htm:

<script type="text/javascript"><!-- Hide script from old browsers

if (self==parent)
{
document.write('<META HTTP-EQUIV="refresh" CONTENT="0; URL=frameset.html">')
}

// end hide -->
</script>

Where frameset.html is the name of your frameset page.

The biggest trouble with this method is that the frameset will open with the default pages specified in frameset.html, not necessarily with the page the user originally wanted.

You should really consider replacing the frames and using techniques such as server-side includes, as frames have major usability problems and are far from being search-engine friendly.

tedster

5:41 pm on Mar 25, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Check into the solution on Message 21 of our Generic Javascript [webmasterworld.com] thread. It will give your visitors who come from search engines the exact page they want, but inside the parent frameset instead of orphaned.