Ok, I dont give up :-)
I have tested some new code to try to prevent double clicks.
In the index page I have at the top:
<script type="text/javascript">
var userAgent = navigator.userAgent.toLowerCase();
var isiPhone = (userAgent.indexOf('iphone') != -1 ||
userAgent.indexOf('ipod') != -1) ? true : false;
clickEvent = isiPhone ? 'tap' : 'click';
</script>
And in the onDeviceReady function I have:
$(this).bind(clickEvent, function(e) {
e.preventDefault();
alert('you just index this ' + clickEvent + 'ed me');
});
The alert is showed when I click my "Back" buttons to go back the the
previus page.
But not if I go to a new page?
And in the head I have:
$(document.body).ready(function(){
$('.fade').bind(clickEvent, function(e) {
e.preventDefault();
alert('you just fade ' + clickEvent + 'ed me');
});
});
The thing is that the fade alert is only working when I click a link
in the index file, not if I click a link with the class fade in any of
my subpages(I get all my pages as ajax pages).
What Im I missing?
Any input appreciated.
Thanks!