X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=include%2Foutput.php;h=a0b9df3c698b0b573726b3727c8c02392891fe3e;hp=16376031c8d94a6f61f1e6de92ab405d97a9138e;hb=932a309e7db3043fd22bd497a1f50b0ba09d112f;hpb=09515348107d9aab7823a12d31b082a2ebb75555 diff --git a/include/output.php b/include/output.php index 1637603..a0b9df3 100644 --- a/include/output.php +++ b/include/output.php @@ -1,5 +1,5 @@ \n"; - echo "

Settings

\n"; - echo "Change password
"; - - echo "
Card set
\n"; - if( $PREF["cardset"] == "english" ) - echo "Change to German cards
"; - else - echo "Change to English cards
"; - - echo "
Email
\n"; - if( $PREF["email"] == "emailaddict" ) - echo "Change to non-addicted mode (emails for each move)
"; - else - echo "Change to addicted mode (minimal amount of emails)
"; - - echo "\n"; - - return; -} - function output_ask_for_new_game($playerA,$playerB,$playerC,$playerD,$oldgameid) { global $RULES; + echo "
\n
\n"; echo "Do you want to continue playing?(This will start a new game, with the next person as dealer.)\n"; echo " \n"; echo " \n"; @@ -46,20 +22,18 @@ function output_ask_for_new_game($playerA,$playerB,$playerC,$playerD,$oldgameid) echo " \n"; echo " \n"; echo " \n"; - + echo "
\n
"; return; } function output_form_for_new_game($names) { ?> -

Players

-

Please select four players (or use the randomly pre-selected names)

-

Remember: you need to be one of the players ;)

-
+ +

Select players (Remember: you need to be one of the players)

- table + table \n"; $i++; - echo " Name: \n \n"; foreach($names as $name) { if($name==$rand) @@ -84,6 +58,7 @@ function output_form_for_new_game($names) } ?>
+

Rules

Some areas are grayed out which means that the rule is not implemented yet and therefore cannot be selected

Ten of hearts: @@ -121,6 +96,51 @@ function output_form_for_new_game($names) \n"; + else + $HTML = "\n\n"; + + $i=0; + + if($caption!="") + $HTML .= " \n"; + + foreach($data as $record) + { + if(!$i) + $HTML .= " \n \n"; + else + { + if($i==1) $HTML .= " \n"; + if($i % 2) + $HTML .= " "; + else + $HTML .= " "; + } + foreach($record as $point) + { + if($i) + $HTML .= " "; + else + $HTML .= " "; + } + + if(!$i) + $HTML .= " \n \n"; + else + { + $HTML .= " \n"; + } + $i++; + } + $HTML .= " \n
$caption
$point$point
\n"; + + return $HTML; +} + function display_card($card,$dir="english") { /* cards are only availabl for the odd values, e.g. 1.png, 3.png, ... @@ -225,7 +245,6 @@ function output_form_calls($me) "
"; } - function output_check_want_to_play($me) { ?> @@ -242,64 +261,6 @@ function output_check_want_to_play($me) return; } -function output_home_page($pre,$game,$done,$avgtime) -{ - global $WIKI; - - echo"

If you want to play a game of Doppelkopf, you found the right place ;)". - " For more information please visit our wiki.

"; - - if($pre == 0) - echo "

At the moment there are no games that are being started "; - else if($pre==1) - echo "

At the moment there is one games that is being started "; - else - echo "

At the moment there are $pre games that are being started "; - - echo "and "; - - if($game==0) - echo "zero games that are ongoing. "; - else if($game==1) - echo "one game that is ongoing. "; - else - echo "$game games that are ongoing. "; - - echo "
\n"; - - if($done==0) - echo "No game has been completed on this server.

"; - else if($done==1) - echo "One game has been completed on this server.

"; - else - echo "$done games have been completed on this server. Average time of a game: $avgtime days

"; -?> - -

Please register, in case you have not done that yet
- or login with you email-address or name and password here: -

- -
- Login - - - - - - - - - - - -
-
-
- -e-Doko - + @@ -375,15 +349,20 @@ function output_footer() function output_status() { - global $defaulttimezone; + global $defaulttimezone,$INDEX,$WIKI; if(isset($_SESSION["name"])) { $name = $_SESSION["name"]; /* logout info */ - echo "\n
"; - echo $name; - echo " logout"; + echo "\n
\n"; + echo $name,"\n"; + echo " | mypage \n"; + echo " | settings\n"; + echo " | new game\n"; + echo " | statistics\n"; + echo " | wiki\n"; + echo " |    logout\n"; echo "
\n"; /* last logon time */ @@ -400,6 +379,28 @@ function output_status() return; } +function output_select_timezone($name,$timezone="") +{ + $Tzone = array ( "Europe/London" => "London", + "Europe/Berlin" => "Berlin", + "America/Vancouver" => "Berkeley", + "Pacific/Auckland" => "Wellington" ); + + echo " \n"; + + return; +} + + function output_password_recovery($email,$password) {