"<script src=\"http://code.jquery.com/mobile/1.3.1/jquery.mobile-1.3.1.min.js\"></script>\n";
$swipescript = "<script>
\$(document).on('pageinit',function(){
- var page = \"#\" + \$(this).attr(\"id\");
- \$(document).on('swiperight',page,function(){
- \$.mobile.changePage('$blink');
- console.log('swiperight');
- });
- \$('#images').on('swipeleft',page,function(){
- \$.mobile.changePage('$nlink');
- console.log('swipeleft');
+ \$('#images').bind('swipeleft',function(){
+ \$.mobile.changePage('$nlink');
});
+ \$('#images').bind('swiperight',function(){
+ \$.mobile.changePage('$blink');
+ });
});
</script>\n";
print $swipescript;