javascriptjqueryjquery-mobilejquery-mobile-ajax

JQuery Mobile loading style and scripts on refresh


The way JQM loads pages is by getting the element with the attribute data-role="page" via ajax, and not the whole document.

So, how do I make JQuery Mobile load the styles and scripts from any page (or a refresh), rather than only loading them in the entry point (index.htm)?


Solution

  • Just put them into the BODY tag.

    It is described in my other answer: Why I have to put all the script to index.html in jquery mobile