From 0133251e523b1c984b2b5cdb60c7392c18e6bd73 Mon Sep 17 00:00:00 2001 From: piernov Date: Wed, 27 Apr 2016 19:51:32 +0200 Subject: Add button for saving on server/downloading the game --- index.xhtml | 2 ++ js/craftmine.js | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/index.xhtml b/index.xhtml index aa29615..d12585f 100644 --- a/index.xhtml +++ b/index.xhtml @@ -32,6 +32,8 @@
+ +
diff --git a/js/craftmine.js b/js/craftmine.js index 92fa45a..13dd0a2 100644 --- a/js/craftmine.js +++ b/js/craftmine.js @@ -60,6 +60,14 @@ function updateMine() { updateData("mine"); } +function saveGame() { + sendRequest("craftmine.php", "op=saveGame"); +} + +function downGame() { + window.open("craftmine.php?op=downGame", "_blank"); +} + function init() { initCraftMine(); changeTab(); -- cgit v1.2.3-70-g09d2