Jquery mobile 不同文件上的内容

Jquery mobile 不同文件上的内容,jquery-mobile,Jquery Mobile,可以将导航栏的内容放在Jquery Mobile上的不同文件中吗?我有一个有很多选项的导航栏,现在这个文件太大了,所以我想把它分成不同的文件。现在我有这样的事情: <div data-role="content"> <div id="content1"> <p>This is 1 (How to put this on another page?)</p> </div> <div id="cont

可以将导航栏的内容放在Jquery Mobile上的不同文件中吗?我有一个有很多选项的导航栏,现在这个文件太大了,所以我想把它分成不同的文件。现在我有这样的事情:

<div data-role="content">
    <div id="content1">
    <p>This is 1 (How to put this on another page?)</p>
    </div>

    <div id="content2">
    <p>This is 1 (How to put this on another page?)</p>
    </div>

    <div id="content3">
    <p>This is 1 (How to put this on another page?)</p>
    </div>
  </div>

这是1(如何将其放到另一页?)

这是1(如何将其放到另一页?)

这是1(如何将其放到另一页?)

是否可以将内容放在不同的文件中?我不需要重定向到另一个页面,我需要的是在同一页面中显示内容,即使内容在另一个文件中。

您可以使用该方法从文件加载外部页面

例如:

$("#loadpage" ).on( "click", function() {
   $.mobile.loadPage( "../templates/about.html");
});