X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=include%2Fgame.php;h=fb807c74ed4533da18ccdc4da77e2f8c159e9e14;hp=7109c11e1ca3560aa25ee7e4db88056b0a1fb1ce;hb=11882439a450641bf0d4dd048775d0bdfb592642;hpb=c3b1dec40c80f8a18f0102505c9f47a2b0d1b335 diff --git a/include/game.php b/include/game.php index 7109c11..fb807c7 100644 --- a/include/game.php +++ b/include/game.php @@ -109,7 +109,15 @@ if( $mystatus!='gameover' ) if($note != '') DB_insert_note($note,$gameid,$myid); }; -output_user_notes($myid,$gameid,$mystatus); + +/* make sure that we don't show the notes to the wrong person + * (e.g. other people looking at an old game) + */ +if( $mystatus != 'gameover' || + ( $mystatus == 'gameover' && + isset($_SESSION['id']) && + $myid == $_SESSION['id'])) + output_user_notes($myid,$gameid,$mystatus); /* handle calls */ if(myisset('call') && $_REQUEST['call'] == '120' && can_call(120,$me)) @@ -131,41 +139,41 @@ if($session) switch($RULES['dullen']) { case 'none': - echo "\n"; break; + echo " \n"; break; case 'firstwins': - echo "\n"; break; + echo " \n"; break; case 'secondwins': - echo "\n"; break; + echo " \n"; break; } switch($RULES['schweinchen']) { case 'none': - echo "\n"; break; case 'both': - echo "\n"; break; case 'second': - echo "\n"; break; case 'secondaftercall': - echo "\n"; break; } switch($RULES['call']) { case '1st-own-card': - echo "\n"; break; + echo " \n"; break; case '5th-card': - echo "\n"; break; + echo " \n"; break; case '9-cards': - echo "\n"; break; + echo " \n"; break; } - echo "