[jQuery] Setting Height in FF
I am having some trouble in FF 1.5.0.7 on Win XP.It works in IE but not in FF. Am I doing this wrong? Is there a workaround?GlenCode Snippet: script$(document).ready(function() { var rightHeight = $(#right).height(); $(#left).height(rightHeight);}); /script style #left { border: 1px solid red; float:left; width: 200px } #right { border: 1px solid red; float:left; width: 200px } /style /head body div id=leftthis is the left /divdiv id=right this is the rightthis is the rightbr /this is the rightthis is the rightbr / this is the rightthis is the rightbr / this is the rightthis is the rightbr /this is the rightthis is the rightbr / this is the rightthis is the rightbr //div ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] Setting Height in FF
Glen, You need to append the px on the end. A call to $(#right).height(); simply returns the integer, to set height, according to the jquery-1.0.2 API, you need the px: script $(document).ready(function() { var rightHeight = $(#right).height(); $(#left).height(rightHeight + px); }); /script -- View this message in context: http://www.nabble.com/Setting-Height-in-FF-tf2467829.html#a6880321 Sent from the JQuery mailing list archive at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] Setting Height in FF
Ugh. Thank you!GlenOn 10/18/06, nezza [EMAIL PROTECTED] wrote: Glen,You need to append the px on the end.A call to $(#right).height(); simply returns the integer, to set height,according to the API, you need the px:script $(document).ready(function() { var rightHeight = $(#right).height();$(#left).height(rightHeight + px);});/script--View this message in context: http://www.nabble.com/Setting-Height-in-FF-tf2467829.html#a6880321Sent from the JQuery mailing list archive at Nabble.com.___jQuery mailing listdiscuss@jquery.comhttp://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/