asp.net mvc - JqueryMobile page initialization function -


i using master page on jquery-mobile app have few controller , , want set javascript call initialize function on every page when loads through ajax,

iam sure there few ways that, whats best approach , alternative $(document).ready when page called through ajax instead of being directly loaded without that.

jquery mobile docs - events

$('div').live('pageshow',function(event, ui){   alert('this page hidden: '+ ui.prevpage); }); 

or

$(document).bind("pageshow".function(){   // initialize code here }); 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -