O'Reilly logo

PhoneGap 3.x Mobile Application Development HOTSHOT by Kerri Shotts

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Displaying scores

Submitting scores is great, but the whole point is to be able to compare ourselves against the rest of the world. To do that, we need to create a new view: the High Scores view. When done, it will look like what is shown in the following screenshot:

Displaying scores

Just for full disclosure, all these scores are mine and not of the people mentioned in the preceding screenshot. This is just a nice shout-out to some of those who have been involved with the book.

Getting on with it

First, let's create a couple of templates. The main template will be for the view, while each particular score will have a simpler template.

In www/html/highScoresView.html ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required