2013-03-05 33 views
0

這是我工作的一些代碼,但現在JQuery Mobiles元素正在工作。自從我編碼以來已經有一段時間了。此外,如果它很重要,我使用Sumlime Text 2.在JQuery Mobile中遇到了一些麻煩

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
    <title>.......</title> 
    <meta name="viewport" content="width=device-width, initial-scale=1"> 
    <link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.css" /> 
    <script src="http://code.jquery.com/jquery-1.8.2.min.js"></script> 
    <script src="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.js"></script> 
</head> 

<body> 
    <div date-role="page" data-theme="a"> 
     <div date-role="header"> 
      <!--Main Nav Bar--> 
      <a href="MainPage.html" data-icon="home" data-iconpos="right">Home</a> 
      <h1>HOME</h1> 
     </div> 

     <div data-role="content"> 
      hello 
     </div> 
    </div> 
</body> 
</html> 

回答

0

從外觀上看,一切似乎寫得都正確。唯一可能的是它不使用正確的HTML 5文檔類型,但是使用了html4。 jQuery Mobile的是HTML5

<!doctype html> 
<html lang="en"> 
<head> 
<meta charset="UTF-8"> 
<title>HTML5 Template</title> 
</head> 
<body> 
</body> 
</html> 
+0

嚴重依賴我寫的崇高文本是問題 – 2013-03-05 02:56:30

+0

得到它的拼寫錯誤 – 2013-03-05 03:24:47

+0

啊,很好聽。您應該切換html5文檔類型,但只是一些需要思考的食物。 – mhartington 2013-03-05 03:28:34

相關問題