javascript - jquery mobile swipe functions -
javascript - jquery mobile swipe functions -
i have swipe function set on web app ipad 1 time user swipes right wit finger, takes them lastly page went to. javascript looks
<script> $(document).bind('swiperight', function () { history.back(); });</script> now in mind, if wanted create function more exact, alter particular page, incorporate jqm alter page function?
<script> $(document).bind('swiperight', function () { $.mobile.changepage( "#home", { transition: "slide"} ); });</script> and set attribute data-direction="reverse"?
it should this:
$(document).bind('swiperight', function () { $.mobile.changepage("#home", { transition: "slide", reverse: true }); }); javascript jquery ios jquery-mobile
Comments
Post a Comment