X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=include%2Foutput.php;h=bbd16af4360565291484c42d6734f585908e578d;hp=6d7deb7e69f3e08c5d87ac04d92a74e121324a1e;hb=11882439a450641bf0d4dd048775d0bdfb592642;hpb=5aa7d5dd2d0b487188fef191c6e5ef38f13e38f7 diff --git a/include/output.php b/include/output.php index 6d7deb7..bbd16af 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; @@ -54,13 +29,11 @@ function output_ask_for_new_game($playerA,$playerB,$playerC,$playerD,$oldgameid) 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"; + echo "
\n"; $i++; - echo " Name: \n \n"; foreach($names as $name) { if($name==$rand) { - echo " \n"; + echo " \n"; } else - echo " \n"; + echo " \n"; } - echo " \n
\n"; + echo " \n
\n"; } ?> +

Rules

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

-

Ten of hearts: -

-

-

Schweinchen (both foxes), only in normal games or silent solos: -

+

Call Re/Contra, etc.:

+
\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, ... * convert even cards to the matching odd value */ - if( $card/2 - (int)($card/2) == 0.5) + if( $card/2 - (int)($card/2) == 0.5 || $card == 0) echo "\"".DB_get_card_name($card)."\"\n"; else echo "\"".DB_get_card_name($card-1)."\"\n"; @@ -226,7 +242,6 @@ function output_form_calls($me) "
"; } - function output_check_want_to_play($me) { ?> @@ -243,64 +258,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 - - + +
-

Welcome to E-Doko (beta)

+

Welcome to E-Doko

der Spielkartenfabrik Altenburg GmbH,(c) ASS Altenburger
\n". " - ASS Altenburger Spielkarten - Spielkartenfabrik Altenburg GmbH
\n". " a Carta Mundi Company Email: info@spielkarten.com Internet: www.spielkarten.com

\n"; - echo "

See the latest changes \n". + echo "

See the latest changes \n". " via git
or download the source via
\n'git clone http://nubati.net/git/e-DoKo.git'
\n". " \n". " \"Green"; - 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 */ @@ -396,11 +335,37 @@ function output_status() $unixtime = strtotime($time); date_default_timezone_set($zone); - echo "
last login: ".date("r",$unixtime)."
\n"; - }; + echo "
last login: ".date("r",$unixtime)."
\n"; + } + else + { + echo "\n
\n"; + echo "login\n"; + echo "
\n"; + } 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) { @@ -433,4 +398,18 @@ function output_password_recovery($email,$password) Personal notes:
\n"; + $notes = DB_get_notes_by_userid_and_gameid($userid,$gameid); + foreach($notes as $note) + echo "$note
\n"; + if($userstatus!='gameover') + echo "\n"; + echo " \n"; + + return; +} + ?> \ No newline at end of file