I’m using this jquery script for extending a child DIV 100%. It works fine, but the DIV is extending beyond the browser window so I must scroll down always. Is it possible to change the 100% height to be related to a parent DIV rathe than the document?
$(document).ready(function () {
$("#stretch").animate({ height: $(document).height() }, 500 );
});
Sure it is:
For direct parent:
http://jsfiddle.net/RRqr4/
If it’s not the direct parent, you can substitute
closestforparent.