X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=index.php;h=29b3eb13898411cc516c4e9a651ee583329a7325;hp=6208038dce9bfb09ddb3fef18139418394938b40;hb=bae8dd0032b45f632e85f12693debd2f03603f07;hpb=320ebe96e21e08d5fad1a4ccbef241d5defd92bc diff --git a/index.php b/index.php index 6208038..29b3eb1 100644 --- a/index.php +++ b/index.php @@ -1,76 +1,21 @@ - - -
-Please add 4 names, please make sure that the names are correct!
- -\n"; - echo "perhaps the game has been cancled."; - exit(); + echo "perhaps the game has been cancled, check by login in here."; + exit(); } DB_update_user_timestamp($myid); + + /* get some information from the DB */ + $gameid = DB_get_gameid_by_hash($me); $myname = DB_get_name_by_hash($me); $mystatus = DB_get_status_by_hash($me); - - /* get game id */ - $gameid = DB_get_gameid_by_hash($me); switch($mystatus) { @@ -190,9 +134,8 @@ else if(isset($_REQUEST["me"])) check_want_to_play($me); DB_set_hand_status_by_hash($me,'init'); break; - case 'init': - if( !isset($_REQUEST["in"]) || !isset($_REQUEST["update"])) + if( !myisset("in","update") ) { DB_set_hand_status_by_hash($me,'start'); echo "you need to answer both question"; @@ -201,8 +144,8 @@ else if(isset($_REQUEST["me"])) { if($_REQUEST["in"] == "no") { - echo "TODO: email everyone that the game has been canceld$name | ".date("Y-m-d H:i:s")." |
these are the games you are playing in:
\n";
$result = mysql_query("SELECT hash,game_id from Hand WHERE user_id='$uid' AND status<>'gameover'" );
while( $r = mysql_fetch_array($result,MYSQL_NUM))
- echo "game #".$r[1]."
";
+ echo "game #".$r[1]."
";
echo "
Want to start a new game? remember 4 names from the list above and visit ". - "this page.
"; + "this page."; } else { @@ -591,40 +573,13 @@ else if(isset($_REQUEST["me"])) } exit(); } -else if(isset($_REQUEST["register"]) ) +/* page for registration */ +else if(myisset("register") ) { - echo "TODO: convert timezone into a menuIf you want to play a game of Doppelkopf, you found the right place ;)
- Please register, in case you haven't done yet
- or login with you email-address or name and password here:
-