This commit is contained in:
Gnieark 2015-11-28 15:44:16 +01:00
parent a397fc5a5b
commit b30535ebfc
2 changed files with 4 additions and 4 deletions

View File

@ -44,7 +44,7 @@ if (isset($_POST['xd_check'])){
} }
//call the good act.php //call the good act.php
if(($currentArena <> "") && (file_exists("../src/arenas/".$currentArena."/act.php"))){ if(($currentArena <> "") && (file_exists("../src/arenas/".$currentArena."/act.php"))){
require_once("../src/arenas/".$currentArena."/act.php"); require_once("../src/arenas/".$currentArena."/act.php");
} }
} }
//title //title
@ -108,4 +108,4 @@ if($currentArena == ""){
<footer> <footer>
</footer> </footer>
</body> </body>
</html> </html>

View File

@ -20,7 +20,7 @@ function tictactoe(bot1,bot2,xd_check){
document.getElementById('fightResult').innerHTML = xhr.responseText; document.getElementById('fightResult').innerHTML = xhr.responseText;
} }
}}; }};
xhr.open("POST", 'index.php', true); xhr.open("POST", '/tictactoe', true);
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xhr.send('act=fight&bot1=' + bot1 + '&bot2=' + bot2 + '&xd_check=' + xd_check); xhr.send('act=fight&bot1=' + bot1 + '&bot2=' + bot2 + '&xd_check=' + xd_check);
} }