summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArun Persaud <arun@nubati.net>2008-01-06 20:01:25 +0100
committerArun Persaud <arun@nubati.net>2008-01-06 20:01:25 +0100
commita5274cbae84c49977d6d1195d8c4e7a3d96391a1 (patch)
tree5f50d968840cd79c73b786482b6b6e6fb6beed61
parenta96688595ffc3663a70754a3a194fc3eeefb5405 (diff)
downloade-DoKo-a5274cbae84c49977d6d1195d8c4e7a3d96391a1.tar.gz
e-DoKo-a5274cbae84c49977d6d1195d8c4e7a3d96391a1.tar.bz2
e-DoKo-a5274cbae84c49977d6d1195d8c4e7a3d96391a1.zip
BUGFIX: show that is is your turn after a new game has been created
if there was no player set for a new game, the user page didn't show that is was your turn in that game Signed-off-by: Arun Persaud <arun@nubati.net>
-rw-r--r--index.php25
1 files changed, 11 insertions, 14 deletions
diff --git a/index.php b/index.php
index 6807fa6..0036433 100644
--- a/index.php
+++ b/index.php
@@ -2196,21 +2196,18 @@ else if( myisset("email","password") || isset($_SESSION["name"]) )
if($r[4] != 'gameover')
{
echo "</td><td>\n ";
- if($r[3])
+ if($r[3]==$myid || !$r[3])
+ echo "(it's <strong>your</strong> turn)\n";
+ else
{
- if($r[3]==$myid)
- echo "(it's <strong>your</strong> turn)\n";
- else
- {
- $name = DB_get_name_by_userid($r[3]);
- $gameid = $r[1];
- if(DB_get_reminder($r[3],$gameid)==0)
- if(time()-strtotime($r[2]) > 60*60*24*7)
- echo "".
- "<a href=\"$INDEX?remind=1&amp;me=".$r[0]."\">Send a reminder.</a>";
- echo "(it's $name's turn)\n";
- };
- }
+ $name = DB_get_name_by_userid($r[3]);
+ $gameid = $r[1];
+ if(DB_get_reminder($r[3],$gameid)==0)
+ if(time()-strtotime($r[2]) > 60*60*24*7)
+ echo "".
+ "<a href=\"$INDEX?remind=1&amp;me=".$r[0]."\">Send a reminder.</a>";
+ echo "(it's $name's turn)\n";
+ };
if(time()-strtotime($r[2]) > 60*60*24*30)
echo "".
"<a href=\"$INDEX?cancel=1&amp;me=".$r[0]."\">Cancel?</a>".