Welcome to WebmasterWorld Guest from 54.226.45.241

Forum Moderators: incrediBILL

Message Too Old, No Replies

How to remove the iFrame scrollbars

     

Rain_Lover

7:16 pm on Sep 3, 2011 (gmt 0)

5+ Year Member Top Contributors Of The Month



Hi,

I wonder why the following iFrame has scrollbars:

<iframe width='600' height='200' frameborder='0' scrolling='no' src='https://docs.google.com/spreadsheet/pub?hl=en_US&key=0Aliqp0kGPjWsdERacHFDVzNzb1N3RHREZzYwVGQ5OVE&output=html&widget=true&chrome=false'></iframe>


Thanks in advance!
Mike

penders

8:52 pm on Sep 3, 2011 (gmt 0)

WebmasterWorld Senior Member penders is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month



The IFRAME doesn't, but an element (a DIV) inside the framed document does.

birdbrain

8:59 pm on Sep 3, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi there Rain Lover,

if you don't want scrollbars then you will have to change the iframe width and height attributes. ;)

So...
<iframe width='800' height='254'...

...instead of...
<iframe width='600' height='200'...

bidbrain

Golden_Sin

6:29 pm on Sep 13, 2011 (gmt 0)



If you don't want to have scrollbars, you can use "overflow" CSS property.

overflow:hidden;

should do the job. If you use this, everything looks the same except there are no scrollbars. So some of the content may not be shown. And of course, this works only if you can modify the CSS of the iframed document.
 

Featured Threads

Hot Threads This Week

Hot Threads This Month