X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=include%2Foutput.php;h=279d4a43c05831ae2c9206276361caa597ff875c;hp=395e4ec812cc8a171b09c2db9e4802cdfa99c973;hb=e2db7fab7569c20afa4f7915edb70842ae1aed8e;hpb=44e91af3fd631752e4de74673b591bce17ce7a79
diff --git a/include/output.php b/include/output.php
index 395e4ec..279d4a4 100644
--- a/include/output.php
+++ b/include/output.php
@@ -1,4 +1,23 @@
+ *
+ * This file is part of e-DoKo.
+ *
+ * e-DoKo is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * e-DoKo is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with e-DoKo. If not, see .
+ *
+ */
+
/* make sure that we are not called from outside the scripts,
* use a variable defined in config.php to check this
*/
@@ -7,21 +26,38 @@ if(!isset($HOST))
/* functions which only ouput html */
+function autoversion($file)
+{
+ /* changes the file name of e.g. css/style.css to css/style..css/js
+ * this way the browser can cache the file and will reload it if the file changed
+ * needs to have .htaccess set up correctly to link back to css/style.css */
+
+ /* only use it for file that have an absolut path */
+ if(!file_exists(dirname($_SERVER['SCRIPT_FILENAME']). '/' . $file))
+ return $file;
+
+ $md5 = md5_file(dirname($_SERVER['SCRIPT_FILENAME']). '/' . $file);
+ return preg_replace('{\\.([^./]+)$}', ".$md5.\$1", $file);
+}
+
+
function output_ask_for_new_game($playerA,$playerB,$playerC,$playerD,$oldgameid)
{
global $RULES;
echo "
\n\n
";
return;
}
@@ -32,94 +68,137 @@ function output_form_for_new_game($names)
* after we selected them to make sure that each name
* only shows up once
*/
-?>
- ';
+
}
-function output_table($data,$caption="",$class="")
+function output_table($data,$caption="",$class="",$id="")
{
+
+ $HTML = "\n
- Do you want to play a game of DoKo?
- yes
- no
-';
+ echo ' '._('Do you want to play a game of DoKo?').' ';
+ echo ' '._('yes').'';
+ echo ' '._('no').' ';
echo "\n";
echo "\n";
- echo "\n";
+ echo "\n";
echo "