- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If I start a new project with HTML5 + Cordova, and I select jquery-mobile as the framework, I don't see any code that loads jquery or jquery-mobile. Shouldn't there be a couple of <script src=... in one of .js files?
I should also note that the reason I want jquery-mobile is to be able to run some javascript when a page loads, e.g.
$(document).on("pageshow","#pagetwo",function(){ // When entering pagetwo
alert("pagetwo is now shown");
});
Is there's a better way to do this?
Thanks,
-dk
- Tags:
- HTML5
- Intel® XDK
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The jquery.mobile scripts and stylesheets will be added after you drag and drop some UI component in the "design" view.
Go to "design" view in the develop tab, drag the header or button, and then switch to "code" view, you will see the jquery js and css added to the index.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Found a simple solution:
<body onpageshow="welcomePage()"> will fire the welcomePage() function in app.js anytime the page (in my case welcomePage.html) is loaded. Exactly what I need.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page