Bug Tracker

Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#6746 closed bug (duplicate)

Wrong $(elem).height() in Mobile Safari when height is implicit

Reported by: davidhkc Owned by:
Priority: undecided Milestone: 1.4.3
Component: core Version: 1.3.1
Keywords: implicit height mobile safari webkit iphone ipad ipod Cc:
Blocked by: Blocking:

Description

Sample DOM: <div id="bar"><div>asdf</div></div>

Sample CSS: .bar { padding-top: 2px; } .bar > div { height: 30px; }

Sample code/output: $("#bar").height(); 0 $("#bar").outerHeight(); 2 $("#bar").children('div').height(); 30 $("#bar").children('div').outerHeight(); 30

On normal browsers, $("#bar").height() == 30 and $("#bar").outerHeight() == 32.

(tested in iPod/iPad)

Change History (2)

comment:1 Changed 13 years ago by addyosmani

Priority: undecided
Resolution: duplicate
Status: newclosed

Duplicate of #6724. There currently appears to be a generic issue with obtaining the desired height values of elements (and the window) with Mobile Safari. Moving discussion to #6274 for this bug.

comment:2 Changed 13 years ago by addyosmani

Duplicate of #6724.

Note: See TracTickets for help on using tickets.