Log in

View Full Version : Using an anchor tag inside of an inline frame



BrightStarPro
10-19-2006, 01:23 PM
Hey everyone,

I've have a website where I post a fairly regular blog. The website is comprised of inline frames (where the blog appears). When a person reaches the bottom of that frame, you have the option of clicking a link that will take the reader to the next page of the blog. Because its in a frame, clicking the link will take the reader to the BOTTOM of the next page, rather than the top. I solved this problem, but including a "top" anchor in each page, and including #top at the end of each "next page" link. This solved the problem for Firefox users, however IE users still suffer the problem of being brough to the bottom of the next page(though it works at random and seldom times).

Any ideas or solutions on this one?

blm126
10-20-2006, 01:26 AM
Just another reason not to use frames. However, you could try adding window.top.scrollTo(0,0) to the onclick of the link.Like this


<a href="somepage.html" onClick="window.top.scrollTo(0,0)">Next Page</a>