[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

document.body.scrollHeight + designMode ON

Posted on 2007-03-21
4
Medium Priority
?
1,296 Views
Last Modified: 2013-12-08
I have an iframe with designMode ON.  For some reason elem.document.body.scrollHeight DOES NOT change in MSIE as you add content to the element (which is editable because of designMode).  I've tested it in both MSIE 6 and 7.  Anyone know what I'm doing wrong?
0
Comment
Question by:inxil
  • 3
4 Comments
 
LVL 3

Accepted Solution

by:
exoska earned 2000 total points
ID: 18765657
document.frames.<frameNameHere>.document.body.scrollHeight

should work out for IE.

and for some more cross-browser look

window.frames.<frameNameHere>.document.body.scrollHeight
0
 
LVL 3

Expert Comment

by:exoska
ID: 18765711
for some instance

here is the main Page:
<HTML>
<HEAD>

</HEAD>
<BODY ONLOAD="document.editFrame.document.designMode= 'On';">
<IFRAME SRC="New3.html" NAME="editFrame"></IFRAME>
</BODY>
</HTML>


here is the iframe : New3.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
  <meta http-equiv="content-type" content="text/html; charset=windows-1250">
  <title></title>
  </head>
  <body >
afasfafa
<script>
document.designMode='on' //mooz
</script>
  </body>
</html>
0
 
LVL 7

Author Comment

by:inxil
ID: 18766048
Thank you!  That's screwed up--why is document.frames['elem'] any different than document.getElementById('elem')?
0
 
LVL 3

Expert Comment

by:exoska
ID: 18766100
buddy there are some words on it at msdn, you might want to check out.
http://msdn.microsoft.com/workshop/author/dhtml/reference/objects/iframe.asp
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Suggested Courses

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question