-1

From docs here:

Use $(document).bind('pageinit'), not $(document).ready()

I have the ff in a JQM page:

$(document).bind('pageinit',function(event){
    //some code here
});

The page was loaded via ajax in JQM page, but it was NOT triggered at all. How to make it work?

Thanks

JR Galia
  • 17,229
  • 19
  • 92
  • 144

1 Answers1

1

try this, it's from the doc

$( '#aboutPage' ).live( 'pageinit',function(event){
  alert( 'This page was just enhanced by jQuery Mobile!' );
});
Jonathan de M.
  • 9,721
  • 8
  • 47
  • 72