[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

jQuery height not working for IE?

Posted on 2010-11-12
4
Medium Priority
?
748 Views
Last Modified: 2012-05-10
This works perfectly in Firefox. The box appears in the bottom right corner of the parent Div with a starting height of 200.Why doesn't it work in IE? Any fix for this?


<html>
<head>

<link type="text/css" href="jquery-ui-1.8.6.custom.css" rel="stylesheet" />      
<script type="text/javascript" src="jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="jquery-ui-1.8.6.custom.min.js"></script>


<script>
$(function() {
    $("#dialog").dialog( { width: 200, height: 200 }).parent().position({ my: 'right bottom', at: 'right bottom', of: '#parent' });
});
</script>
</head>

<body>


<style>#parent { border: solid 1px #ddd; width: 500px; height: 400px; }</style>

<div id="parent">
</div>

<div id="dialog">
Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />Test Content<br />
</div>


</body>
</html>
0
Comment
Question by:tonyhhisc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 16

Accepted Solution

by:
Justin Mathews earned 2000 total points
ID: 34121795
Try either:

<script>
$(function() {
    $("#dialog").dialog( { width: 200, height: 200 }).css("height", "200px").css("overflow", "scroll").parent().position({ my: 'right bottom', at: 'right bottom', of: '#parent' });
});
</script>


OR this if you want overflow with scroll bars:


<script>
$(function() {
    $("#dialog").dialog( { width: 200, height: 200 }).css("height", "200px").css("overflow", "scroll").parent().position({ my: 'right bottom', at: 'right bottom', of: '#parent' });
});
</script>
0
 
LVL 16

Expert Comment

by:Justin Mathews
ID: 34121831
Sorry if want overflow hidden it should be:

<script>
$(function() {
    $("#dialog").dialog( { width: 200, height: 200 }).css("height", "200px").css("overflow", "hidden").parent().position({ my: 'right bottom', at: 'right bottom', of: '#parent' });
});
</script>
0
 

Author Comment

by:tonyhhisc
ID: 34136365
EXCELLENT! Thanks a million!
0
 

Author Closing Comment

by:tonyhhisc
ID: 34136366
You rock!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

649 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