Note that there are some explanatory texts on larger screens.

plurals
  1. POHow Load html files into data-role=page with jquery mobile and phonegap?
    primarykey
    data
    text
    <p>I want this: load html files into data-role=page with jquery mobile and phonegap: My project have a lot of small HTML files with independent pages.</p> <p>I use:</p> <p>index.html:</p> <pre><code>&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;meta charset="utf-8"&gt; &lt;title&gt; Inicio :: Autenticacion &lt;/title&gt; &lt;meta name="viewport" content="width=device-width,height=device-height, initial-scale=1"&gt; &lt;link rel="stylesheet" href="jsmobile/jquery.mobile-1.2.0.min.css" type="text/css"&gt; &lt;script src="jsmobile/jquery.js" type="text/javascript"&gt;&lt;/script&gt; &lt;script src="jsmobile/jquery.mobile-1.2.0.min.js" type="text/javascript"&gt;&lt;/script&gt; &lt;script language="javascript" type="text/javascript"&gt; $(document).ready(function() { $('#boton').bind('click', function(event) { $.mobile.loadPage("Fichero/index.html",{pageContainer:$("#container1")}); }); }); &lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;div data-role="page" id="container0"&gt; &lt;div data-role="content"&gt; &lt;a id="boton" &gt;Change Page&lt;/a&gt; &lt;/div&gt; &lt;/div&gt; &lt;div id="container1"&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>File: Fichero/index.html</p> <pre><code>&lt;div date-role="page" id="micro"&gt; &lt;div data-role="header" &gt; &lt;h1&gt;Test Heas&lt;/h1&gt; &lt;/div&gt;&lt;!-- /header --&gt; &lt;div data-role="content" &gt; Test here.. &lt;/div&gt;&lt;!-- /content --&gt; &lt;/div&gt; </code></pre> <p>and I want load html content from Fichero/index.html in container1 when user click on Change Page link, but It doesn't works.</p> <p>It load content into the DIV id="container1" and the DOM, but not showed/refresed (is like hidden).</p> <p>What is the method to do a simple html file external load and the DOM be refreshed and visible the HTML code load?</p> <p>Thanks in advance.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload