954,591 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Iframe Dimensions

Hi,

When I set width and height properties in the tag, it sets the width and height respectively, however, the "src" page inside the iframe is still small and has a scroll bar. Is there a way to set the src to be equal to the iframe dimensions?

Thanks,
Ashton.

AshtonHogan
Posting Whiz in Training
210 posts since Jul 2009
Reputation Points: 7
Solved Threads: 1
 

No, the iframe is displaying another web page. Unless you have access to that page, in which case you would have to make the page fit within the iframe - the iframe has a width and height of 500px, then the actual page itself has to be within 500px.


Regards, Arkinder

Arkinder
Posting Pro in Training
454 posts since Nov 2010
Reputation Points: 113
Solved Threads: 59
 

you can set the height and width values to 100% and it will show the page the same size as if you were on the site, or if you just want to get rid of the scroll bars you can use:

<iframe src="page_whatever.html" title="anything" scrolling="no">

also, you can remove the border with

<iframe src="page_whatever.html" title="anything" scrolling="no" frameborder="0">
bben95
Junior Poster in Training
52 posts since Aug 2010
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: