how to turn a iframe scrollbar off from javascript

D

David

How do you turn an iframe scrollbar off, from within javascript, after
the iframe has been loaded? In my example, the page with the iframe
on it is initially set to scrolling=yes, however, I want to be able to
set the scrollbar=no, through javascript.
 
D

David

That did it: thanks.

mscir said:
David said:
How do you turn an iframe scrollbar off, from within javascript, after
the iframe has been loaded?

This works on my IE6 but NOT on my Netscape 7.1 or Firefox 0.8 :


function noscroll(iframeID) {
document.frames[iframeID].document.body.style.overflow='hidden';
}

<iframe SRC="anchor.htm" name="if1" id="if1" SCROLLING="yes"></iframe>

<input type="BUTTON" onclick="noscroll('if1')" value="no scroll bars">

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,021
Latest member
AkilahJaim

Latest Threads

Top