HighDots Forums  

iframe makes things disappear

Macromedia Dreamweaver Macromedia Dreamweaver Discussions (macromedia.dreamweaver)


Discuss iframe makes things disappear in the Macromedia Dreamweaver forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
mashey
 
Posts: n/a

Default iframe makes things disappear - 11-16-2004 , 01:30 AM






I've used an iframe within a frame in my webpage. However it makes a table
along the bottom of the page dissappear entirely.
I think it is getting rid of everything underneath it.

This is the code I've used.


<iframe src="news.htm" width="100%" height="100%" frameborder="0"><iframe>

How do i fix this?


Reply With Quote
  #2  
Old   
Barry Clark
 
Posts: n/a

Default Re: iframe makes things disappear - 11-16-2004 , 08:27 AM






I think you need to set the iFrame height in pixels (e.g. 2000). However,
you can then get browser scrolling problems, and if you load subsequent
documents into the iFrame you may not see the top of the new document, so
you need to add onload="scrollTo(0,0)" in the body tag of each document
being loaded into the iFrame, then it all works just fine.

--
Dr Barry Clark
Senior Lecturer and Director of VALE
(Virtual Administration and Learning Environment)
Medical Education Unit
Faculty of Medicine
Wolfson Medical School Building
University of Glasgow
Glasgow G12 8QQ
Tel: 0141-330-4248
Email: b.clark (AT) clinmed (DOT) gla.ac.uk
"mashey" <webforumsuser (AT) macromedia (DOT) com> wrote

Quote:
I've used an iframe within a frame in my webpage. However it makes a table
along the bottom of the page dissappear entirely.
I think it is getting rid of everything underneath it.

This is the code I've used.


iframe src="news.htm" width="100%" height="100%"
frameborder="0"><iframe

How do i fix this?




Reply With Quote
  #3  
Old   
David Stiller
 
Posts: n/a

Default Re: iframe makes things disappear - 11-16-2004 , 08:40 AM



You haven't properly closed your <iframe> tag, so the browser that
everything beneath it is still part of the iframe. Think of tags as
bookends. There are some exceptions, like the <img> and <br> tags, but for
the most part, tags sit on either side of their content.

Your code:
<iframe src="news.htm" width="100%" height="100%" frameborder="0"><iframe>

Should be:
<iframe src="news.htm" width="100%" height="100%" frameborder="0"></iframe>

Look for the slash (/) in the closing <iframe> tag. That's what makes
all the difference.

<iframe ... [attributes]>
.... content
</iframe>


David
stiller ( at ) quip ( dot ) net



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.