I have jQuery code that works fine on desktop browsers;
$("span#checkbox_err").mouseout(function () { $("span#checkbox_err").fadeOut("slow"); });
But the same does not work on the iPad (as a result, checkbox_err is displayed on the screen but never hidden)
How to trigger mouseout event on iPad?
I also want to avoid using an extra library to fix this little problem.
I have the following question
I am testing a page on an iPad and encounter some problems that implement the equivalent of mouse behavior.
So the question is very easy to understand; 1. On my page there is a check box in the click (or rather touch), I want to show errorMsg 2. By pressing / tap nothing but errorMsg, I want to hide errorMsg
Below is the code I wrote:
$(document).bind("touchstart",function(e){ if(e.target.id != "checkbox_err") $("span#checkbox_err").fadeOut("slow"); }); } $("input:checkbox").bind("touchstart",function(){ $("span#checkbox_err").fadeIn("fast"); });
Now the problem is that when I click / touch this checkbox, errorMsg shows for a while and then it also hides it right away (since the target is not errorMsg)
How to fix this problem?
Diana
source share