【发布时间】:2014-11-08 18:37:08
【问题描述】:
您好,我在 PhoneGap 中制作了一个 hello world 类型的应用程序。我在www 目录中有 index.html,但它显示的是 phonegap 的默认主页。请查看它始终显示的附加屏幕截图。
index.html
<html>
<head>
<meta charset="utf-8" />
<meta name="format-detection" content="telephone=no" />
<meta name="msapplication-tap-highlight" content="no" />
<!-- WARNING: for iOS 7, remove the width=device-width and height=device-height attributes. See https://issues.apache.org/jira/browse/CB-4323 -->
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
<link rel="stylesheet" type="text/css" href="css/index.css" />
<title>Hello World</title>
</head>
<body>
<script type="text/javascript" src="cordova.js"></script>
<script type="text/javascript" src="js/index.js"></script>
<script type="text/javascript">
app.initialize();
</script>
<form>
Select your favourite color: <input type="color" name="favcolor">
<br/>
<input type="button" value="SUBMIT" />
</form>
</body>
</html>
但是当我在安卓手机上运行应用程序时,它总是显示这个。我已经完成了 3-4 次重建完整的项目,但还是一样。
我不确定出了什么问题或遗漏了什么。
提前致谢。
【问题讨论】:
-
在你添加的平台构建之前,尝试手动更改 www 文件夹的内容,然后进行构建,看看它是否有效。
-
@ashfaq.p 是的,我也在问题中更改并上传了代码。