I’m using JQuery mobile together with PhoneGap, and I’v been trying to show a string of text on the phone screen through a html page. Most of the text is always the same, but some parts I want to be controlled by variables which I have created inside a namespace using javascript:
$.Game =
{
gName: "global name"
};
I then want to use this variable in the text I want to display, I have tried to find a way to fit it into a paragraph, but it needs to be inside a script tag. Does anyone know how to do this?
You mean like this?
And the jQuery: