Question

I was reading and following along exercise in Jonathan Stark's Building iPhone Apps with HTML, CSS, and JavaScript.

I am having some error in the error console but I doesn't know how to fix it.

Could not find an element with the id "jqt", so the body id has been set to "jqt". If you are having any problems, wrapping your panels in a div with the id "jqt" might help.  jqtouch.js:104

I am using jQTouch b3.1

Please help
Thanks~

Was it helpful?

Solution

That seems more like a warning than an error. I suspect you're using a later version of jQTouch than the one in the book. Earlier version of jQT has pages directly under body, e.g.

<body>
  <div id="page1"></div>
  <div id="page2"></div>
</body>

But later version of jQT has pages under div#jqt, so to allow the inclusion of a fixed navigation bar, e.g. tabbar control:

<body>
  <div id="jqt">
    <div id="page1"></div>
    <div id="page2"></div>
  </div>
  <!-- you could have something fixed navigation element here -->
</body>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top