I am using $.mobile
in my app. I must create my own routing system.
I bind observer on hashchange
and I pull out interesting data from location.h
in your html after including jquery and before including jquery.mobile-1.x.y.js add:
<script>
$(document).bind("mobileinit", function(){
$.mobile.pushStateEnabled = false;
$.mobile.ajaxEnabled = false;
$.mobile.hashListeningEnabled = false;
});
</script>
I believe you are fighting against the "pushState" plugin in jQuery Mobile added in Beta 3 (I believe). You can disable this plugin with the following code (used before you include the jQuery Mobile JavaScript file):
$(document).on('mobileinit', function () {
$.mobile.pushStateEnabled = false;
});
Check-out the documentation here (notice the "pushState Plugin" section): http://jquerymobile.com/demos/1.0rc3/docs/pages/page-navmodel.html