I'm teaching my self to write a web site to help my sister's new business. It's in a three column format.
I put an small iframe on the main page's right column to show her blog, and I put in an anchor point (#iframe_target) in the blog so that the iframe shows the beginning of the content of the blog rather than the top left corner:
Expand|Select|Wrap|Line Numbers
- <iframe
- src="http://DOMAIN.blogspot.com#iframe_target" width="215" height="287"><p>Your browser does not support iframes.</p></iframe>
Can anyone explain what is happening? And better yet, give me idea how to fix either the initial problem (load the iframe content to the specific part of the webpage I want to show) or the subsequent problem (page scrolls up when iframe content loads)
I have one fix, which is to use the following function
Expand|Select|Wrap|Line Numbers
- function jumpScroll() {
- window.scroll(0,0);
- }
Expand|Select|Wrap|Line Numbers
- <body onload="javascript:jumpScroll()" >
Any help will be greatly appreciated!