我使用TextEdit创建了移动jquery的演示页面,即
<!doctype html>
<html>
<head>
<title>My Page</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.css">
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.js"></script>
</head>
<body>
<div data-role="page">
<div data-role="header">
<h1>My Title</h1>
</div><!-- /header -->
<div data-role="content">
<p>Hello world</p>
</div><!-- /content -->
<div data-role="footer">
<h4>My Footer</h4>
</div><!-- /footer -->
</div><!-- /page -->
</body>
</html>
但是,在我的浏览器中代码没有被编译,它显示这些文本,因为它是纯文本..我确认我的浏览器支持HTML5:http://html5test.com/
缺少什么!?
答案 0 :(得分:1)
问题是您使用的浏览器是什么?我在Chrome上尝试了您的代码,但效果非常好。
我的猜测是,你是企业或大学防火墙背后的封锁你的CDN网址。那么为什么不下载jQuery移动文件并在本地放置js,css文件并尝试再次运行该页面?
答案 1 :(得分:0)
src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
答案 2 :(得分:0)
谢谢大家。