Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I navigate between pages inside a PhoneGap application?

I am newbie with PhoneGap and I'm a little bit lost. I have installed and run the example app and it works ok. Now I want to change a little the default app. I want a button or link to change from the current page/view to another I have in the "www" folder. If I use "..." it opens Safari.

How can I navigate between views/pages inside a PhoneGap application?

like image 226
Marta Rodriguez Avatar asked May 27 '11 13:05

Marta Rodriguez


Video Answer


1 Answers

You can use mobile web UI frameworks that work on top of PhoneGap like Sencha Touch or jQuery Mobile. They have view stacks already integrated and are easy to work with.

Or you could do what I do and create your own view stack from scratch, which isn't nearly as hard as it may sound. I use PhoneGap along with xuijs to transition full screen, fixed position divs that represent "views".

Be sure to use CSS3 transitions instead of javascript animation when possible and they will perform much better.

like image 88
Tony Lukasavage Avatar answered Oct 13 '22 15:10

Tony Lukasavage