|
1 <!DOCTYPE HTML> |
|
2 |
|
3 <!-- |
|
4 This is the webapp. It doesn't need to do anything in particular, just |
|
5 whatever you want to test from your browser_ test file. |
|
6 --> |
|
7 |
|
8 <html> |
|
9 <head> |
|
10 <meta charset="utf-8"> |
|
11 <script> |
|
12 |
|
13 function onLoad() { |
|
14 var msg = document.getElementById("msg"); |
|
15 var self = navigator.mozApps.getSelf(); |
|
16 self.onsuccess = function () { |
|
17 msg.textContent = "Webapp getSelf OK: " + self.result; |
|
18 }; |
|
19 self.onerror = function () { |
|
20 msg.textContent = "Webapp getSelf failed: " + self.error.name; |
|
21 }; |
|
22 } |
|
23 |
|
24 </script> |
|
25 </head> |
|
26 <body onload="onLoad();" onunload=""> |
|
27 <p>This is the test webapp.</p> |
|
28 <p id="msg">Webapp waiting for page load...</p> |
|
29 </body> |
|
30 </html> |