From 82185753906709f9944a07c35a809736cf979afe Mon Sep 17 00:00:00 2001 From: root Date: Sun, 2 Mar 2014 00:13:01 +0100 Subject: new folder etc --- www/quote.php | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 www/quote.php (limited to 'www/quote.php') diff --git a/www/quote.php b/www/quote.php new file mode 100644 index 0000000..b0bc136 --- /dev/null +++ b/www/quote.php @@ -0,0 +1,79 @@ +query("SELECT count(*) as count FROM sprueche;"); +$row = $rows->fetchArray(); +$numRows = $row["count"]; + +if ($zufall == ""){ + $zufall = mt_rand(1,$numRows); +} + + +$safe_zufall = SQLite3::escapeString("$zufall"); +$ergebnis = $db->query("SELECT * FROM sprueche where id=$safe_zufall;"); + +echo" + +
JUNGE GEMEINDE ADLERSHOF
+ ,/| _.--''^``-...___.._.,;
+ /, \'. _-' ,--,,,--'''
+ { \ `_-'' ' /}
+ `;;' ; ; ;
+ ._.--'' ._,,, _..' .;.'
+ (,_....----''' (,..--''
+Es sind momentan $numRows Zitate in der Datenbank enthalten.
+Du suchst ein bestimmtes Zitat? Gib hier dessen Nummer ein: +