From fe5ea2f01aa01fb32f9c3dc2334f1636385da192 Mon Sep 17 00:00:00 2001 From: anomen Date: Thu, 31 May 2012 01:15:57 +0200 Subject: [PATCH] gc-fallout - dev --- www-apps/gc-fallout/dev/cert.php | 13 +++++++------ www-apps/gc-fallout/dev/index.php | 2 +- www-apps/gc-fallout/dev/token.php | 1 - 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/www-apps/gc-fallout/dev/cert.php b/www-apps/gc-fallout/dev/cert.php index 3c18754..9c5653a 100644 --- a/www-apps/gc-fallout/dev/cert.php +++ b/www-apps/gc-fallout/dev/cert.php @@ -15,6 +15,10 @@ $U = decodeToken($token); $certimg = imagecreatetruecolor(PERK_WIDTH*3+100, PERK_HEIGHT*3+100); $bg = imagecolorallocate($certimg, 0xd0, 0xd0, 0xd0); +$red_color = imagecolorallocate($certimg, 0xff, 0x00, 0x00); +$text_color = imagecolorallocate($certimg, 0x00, 0xff, 0x00); +$ii = chr(0xED); + imagefill($certimg, 0, 0, $bg); @@ -28,17 +32,14 @@ foreach($U['perky'] as $perk) { $i++; } -$text_color = imagecolorallocate($certimg, 0xff, 0x00, 0x00); for ($i=2; $i < 8; $i ++) { - imagestring($certimg, 5, PERK_WIDTH * 3 / 2, PERK_HEIGHT * ( $i / 3) , 'TEST', $text_color); + imagestring($certimg, 5, PERK_WIDTH * 3 / 2, PERK_HEIGHT * ( $i / 3) , 'TEST', $red_color); } -$text_color = imagecolorallocate($certimg, 0x00, 0xff, 0x00); -$ii = chr(0xED); -imagestring($certimg, 5, 20, 10, "${U[login]}", $text_color); +imagestring($certimg, 5, 20, 10, "${U[login]}", $red_color); imagestring($certimg, 5, 20, 30, "Pen${ii}ze: ${U[penize]} | Karma: ${U[karma]} | J${ii}dlo: ${U[jidlo]}", $text_color); imagestring($certimg, 5, 180, 10, "Skore ${U['skore']}", $text_color); -//imagejpeg($certimg, NULL, 100); +//imagejpeg($certimg, NULL, 90); imagepng($certimg); imagedestroy($certimg); diff --git a/www-apps/gc-fallout/dev/index.php b/www-apps/gc-fallout/dev/index.php index 01c9034..e43092e 100644 --- a/www-apps/gc-fallout/dev/index.php +++ b/www-apps/gc-fallout/dev/index.php @@ -87,7 +87,7 @@ foreach ($params as $p) { echo "
odkaz pro zalogovani:
\n"; - echo "
U=";print_r($U);echo "
"; + //echo "
U=";print_r($U);echo "
"; $token_b64 = getToken($U); $script="http://${_SERVER['SERVER_NAME']}:${_SERVER['SERVER_PORT']}" diff --git a/www-apps/gc-fallout/dev/token.php b/www-apps/gc-fallout/dev/token.php index 4df75a4..750c883 100644 --- a/www-apps/gc-fallout/dev/token.php +++ b/www-apps/gc-fallout/dev/token.php @@ -54,7 +54,6 @@ function getToken($U) for ($i = 0; $i < SEED_LENGTH; $i++) { $plain{$i} = $sha{$i}; } - echo " XXX $plain XXX"; $token = aes_encrypt(PASSWORD, $plain); $token_b64 = base64_url_encode($token); -- 2.11.4.GIT