/*
Begin options
*/
$poll_file = "poll_script.php"; // Change this to the name of the other PHP file downloaded
$poll_cookie_name = "filmi"; // This is the cookie name that is set so that the "Vote" button is hidden on the form - you should change this name each time you change the poll so that previous voters may vote again in the new poll
$poll_results_file = "results.txt"; // Change this to the file that holds the poll results
$poll_redirect_page = "index.php"; // Change this to the page you want to redirect the visitor to after he/she votes
$poll_cookie_expires = 604800; // Change this to the amount of time, in seconds, the cookie stays in the visitor's browser so that he/she may vote again after the cookie expires. 604800 seconds is equal to one week
/*
End options
*/
if(isset($_COOKIE["$poll_cookie_name"]) && $_GET["message"] != "1" && $_GET["message"] != "2" && $_GET["message"] != "3") $message = "Results
";
elseif(!isset($_COOKIE["$poll_cookie_name"]) && !isset($_GET["message"]) || $_GET["message"] < "1" || $_GET["message"] > "3") $message = "Cast your vote below.
";
elseif($_GET["message"] == "1") $message = "Tvoj glas je bil dodan.
";
elseif($_GET["message"] == "2") $message = "Najprej izberi možnost.
";
elseif($_GET["message"] == "3") $message = "Glasujes lahko enkrat na teden.
";
$choices_file = fopen($poll_results_file, "r");
$choices = fread($choices_file, 1024);
$choices = explode("\t", $choices);
fclose($choices_file);
?>
Kateri film ti je bil lansko leto najbolj vsec? =$message?> |