How do I use jQuery for click event in iPhone web application
Posted
by Gazzer
on Stack Overflow
See other posts from Stack Overflow
or by Gazzer
Published on 2010-06-11T18:41:14Z
Indexed on
2010/06/11
22:22 UTC
Read the original article
Hit count: 243
When I use jQuery for a simple click event it only works for links. Is there a way to make it work for spans etc:
$("span.clicked").live("click", function(e){alert("span clicked!")});
$("a.clicked").live("click", function(e){alert("link clicked!")});
Example is here: http://ip1n.j-www.com/test/index2.html
The SPAN works in Safari but not Mobile Safari (on iPhone or iPad) whereas the A tag works in both.
© Stack Overflow or respective owner