For example:
if((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i)) || (navigator.userAgent.match(/iPad/i)) || (navigator.userAgent.match(/Android/i))) {
$("a").bind('touchstart', function(){ $(this).addClass('hover'); }); $("a").bind('touchend', function(){ $(this).removeClass('hover'); });
This should work in theory.