瀏覽代碼

Helios: Confirm before closing the window

Nicolas Petton 11 年之前
父節點
當前提交
bb6b63ce28
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      helios.html

+ 6 - 0
helios.html

@@ -19,5 +19,11 @@
     
     
     <div id="helper">Loading Helios...</div>
     <div id="helper">Loading Helios...</div>
 
 
+    <script type="text/javascript">
+      window.onbeforeunload = function() {
+      return 'Do you want to close Amber? All uncommitted changes will be lost.';
+};
+    </script>
+
   </body> 
   </body> 
 </html> 
 </html>