KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
How can I detect a Scrollbar presence ( using Javascript ) in HTML iFrame ? I have already tried : var vHeight = 0; if (document.all) { if (document.documentElement) { vHeight = document.documentElement.clientHeight; } else { vHeight = document.body.clientHeight } } else { vHeight = window.innerHeight; } if (document.body.offsetHeight > vHeight) { //when theres a scrollbar }else{ //when theres not a scrollbar } And I also had tried : this.scrollLeft=1; if (this.scrollLeft>0) { //when theres a scrollbar this.scrollLeft=0; }else{ //when theres not a scrollbar return false; } With no success.. I have searched the javascript objets on DOM Inspector , but didn't find anything. Is is possible to detect a scrollbar presence in a iframe in javacscript ? The iframe content comes from the same domain. No success until now.. alt text http://www.upvtp.com.br/file.php/1/help_key.jpg
Tags (comma-separated)
Save Edits
Cancel