Skip to main content

Bug Tracker

Side navigation

#13729 closed bug (notabug)

Opened April 04, 2013 09:17AM UTC

Closed April 04, 2013 07:50PM UTC

Last modified August 04, 2013 06:22AM UTC

fadeIn() have a bug in iphone safari browser (jQuery>=1.8.0)

Reported by: jonwang@queyang.com Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.9.1
Keywords: Cc:
Blocked by: Blocking:
Description

I found a special bug of fadeIn. It blinks twice in iphone browser,and In Pc browser is ok.

This bug appear in the version 1.8.0 and higher. In 1.7.2 is ok.

on line debug url: http://jsfiddle.net/jonwang/Xgt5B/

The test code , save it and use iphone test.

If remove the main-div's style "bottom:0",the bug will disappear.

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no" />
<script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.js"></script>
</head>
<body>
<div style="position:absolute;top:150px;z-index:10;">
<input type="button" value="click" onclick="document.location.hash='test'" />
Press the browser Back and Forward buttons after clicked the button.
</div>
<div id="main-div" style="position:fixed;top:0;left:0;right:0;bottom:0">
    <div id="aaaaaa" style="position:absolute;">
    aaaaaaaaaaaaa<br />
    aaaaaaaaaaaaa<br />
    aaaaaaaaaaaaa<br />
    </div>
</div>
<script type="text/javascript">

window.onhashchange = function()
{
    var obja = $('#aaaaaa');
    if (obja.css('display')=='none')
    {
        obja.fadeIn();
    }
    else
    {
        obja.fadeOut();
    }
};

</script>

</body>
</html>
Attachments (0)
Change History (3)

Changed April 04, 2013 09:24AM UTC by anonymous comment:1

My iphone is iphone4,ios 6.1.2

and I test it in ipad mini(ios 6.1.2), the bug still exists.

Changed April 04, 2013 07:50PM UTC by dmethvin comment:2

resolution: → notabug
status: newclosed

There are a lot of things in play here, can you go to a forum and have someone help to isolate the problem? Thanks!

Changed August 04, 2013 06:22AM UTC by anonymous comment:3

Oh my Godddd

Thank you so much finally I can sleep

Stupid everything-i!