目前我正在使用eclipse 3.7中的GWT 2.4.0開發一個GWT項目。我在Tomcat 7中部署應用程序。它在過去的2個月裏運行得非常好。GWT項目無法在默認html文件中加載**。nocache.js
但是,現在我遇到了無法追蹤問題的問題。這裏是「welcomeGWT.html」的源代碼。
<!doctype html>
<!--
The DOCTYPE declaration above will set the browser's rendering engine into
"Standards Mode". Replacing this declaration with a "Quirks Mode" doctype may
lead to some differences in layout.
-->
<html>
<head>
<meta name='gwt:module' content='com.haircare101.cesapp.Main=com.haircare101.cesapp.Main'>
<title>101 HairCare: Customer Excellence System</title>
</head>
<body>
<script type="text/javascript" src="com.haircare101.cesapp.Main/com.haircare101.cesapp.Main.nocache.js"></script>
</body>
</html>
由於Tomcat的開始,我輸入相應的URL到瀏覽器,它讓我看到這個頁面,沒有錯誤(Tomcat的內部日誌文件沒有錯誤顯示)。但它無法將我引導到指定的GWT主入口點(當我可以「瀏覽瀏覽器的源」時看到此源文件)。
**我沒有編譯錯誤,沒有部署錯誤或沒有運行時錯誤。
任何人都可以告訴我爲什麼卡在這個頁面?非常感謝和欣賞!
乾杯, 瑞安C.
是否有瀏覽器的控制檯/開發工具的錯誤? (JS錯誤,或錯誤檢索所需的文件) – 2012-01-02 13:22:59
嘗試從谷歌瀏覽器運行你的應用程序,因爲它可能會顯示你的錯誤其他瀏覽器不會 – 2012-01-02 13:42:36
感謝您的建議〜我看到JavaScript控制檯(谷歌瀏覽器) ...
未捕獲java.lang.IndexOutOfBoundsException (匿名函數)8B0B2BF935822EA071855520D60A5B14.cache.html:2179 gwtOnLoad8B0B2BF935822EA071855520D60A5B14.cache.html:2341個 Bcom.haircare101.cesapp.Main.nocache.js:2 com_haircare101_cesapp_Main。 onScriptLoadcom.haircare101.cesapp.Main.nocache.js:15 (匿名功能)
有人能告訴我腳本發生了什麼嗎? (我沒有更改HTML或JavaScript)。 – 2012-01-02 15:05:57