2012-12-02 57 views
0

最近我开始使用jQuery Mobile作为原生android应用程序(使用phoneGap)。jQuery Mobile中的多个HTML页面

这是我的index.html:

<html> 
<head> 
    <meta charset="utf-8"> 

<meta name="viewport" content="width=device-width, initial-scale=1"> 

<link rel="stylesheet" href="css/rtl.jquery.mobile-1.2.0.min.css" /> 
<link rel="stylesheet" href="css/style.css"> 

<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script> 
<script src="js/rtl.jquery.mobile-1.2.0.min.js"></script> 


    <title>Untitled Document</title> 
</head> 
<body> 
<div class="all_app_position" data-role="homePage"> 
    <div data-role="header" class="header"> 
     header 
    </div> 
    <div class="middle"> 
     Middle contnet 
    </div> 

    <div class="footer"> 
     footer content 
    </div> 

</div> 

</body> 
</html> 

我想导入第二HTML文件内容(如下所示),中间的div。

 <div data-role="page" id="about"> 
     <div data-role="header"><h1>Page 2</h1></div> 
     <div data-role="content"><p id="deviceProperties">Loading device properties...</p></div> 
     <div data-role="footer"><h4>Footer</h4></div> 
    </div> 

我该怎么做? 我尝试了很多方法,但我做不到。

对我很重要的是,链接将使用Ajax。

对不起我的英语

谢谢:)

回答