AppLaud + jQuery Mobile 1.3.1 + jQuery 1.10.1 + Phonegap 1.9.0(为什么不工作?)

时间:2013-07-04 15:43:44

标签: android jquery-mobile cordova applaud

朋友, 我开始使用PhoneGap + jQuery Mobile在AppLaud应用程序中开发。

Applaud开始了一个新项目: - JQuery 1.7.2 - JQuery Mobile 1.3.1 - PhoneGap 1.9.0

我的文件夹资源如下:

- [assets]
- [www]
--- [jquery.mobile]
---- [images]
---- jquery-1.7.2.min
---- jquery.mobile-1.3.1.css
---- jquery.mobile-1.3.1.js
---- jquery.mobile-1.3.1.min.css
---- jquery.mobile-1.3.1.min.js
--- cordova-1.9.0.js
--- index.html

我的index.html文件包含以下内容:

<!DOCTYPE HTML>
<html>
  <head>
    <meta name="viewport" content="width=320; user-scalable=no" />
    <meta http-equiv="Content-type" content="text/html; charset=utf-8">
    <title>Minimal AppLaud App</title>

      <script type="text/javascript" charset="utf-8" src="cordova-1.9.0.js"></script>
      <script type="text/javascript" charset="utf-8">

        var onDeviceReady = function() {
            document.getElementById("devready").innerHTML = "OnDeviceReady fired.";
        };

        function init() {
            document.addEventListener("deviceready", onDeviceReady, true);
        }   
</script>  

  </head>
  <body onload="init();" id="stage" class="theme">
    <h2>Minimal AppLaud App</h2>

    <p>Your app goes here.</p>
    <p>
    <span id="devready">onDeviceReady not fired.</span>
    </p>

  </body>
</html>

我在Eclipse IDE中遇到以下错误:

“令牌上的语法错误”“无效的正则表达式选项”,可以进行准确的更正“ - jquery.mobile-1.3.1.min.js - 第2行

“默认情况已经定义” - jquery.mobile-1.3.1.js - 第2034行

“默认情况已经定义” - jquery.mobile-1.3.1.js - 第8700行

可能会发生什么? 有了这些错误,我甚至无法测试应用程序。

1 个答案:

答案 0 :(得分:0)

我设法解决了这个问题。 实际上Eclipse是一些内部错误。 我已禁用 Project&gt;中的 JavaScript Validator 性状&gt;助洗剂

如果有人遇到这个问题,这就是解决方案。