Skip to content

Instantly share code, notes, and snippets.

@nicoknoll
Created August 1, 2014 14:58
Show Gist options
  • Save nicoknoll/8655c140070441b79dde to your computer and use it in GitHub Desktop.
Save nicoknoll/8655c140070441b79dde to your computer and use it in GitHub Desktop.
<?php
if($_GET['ende']) {
$end = (int)$_GET['ende'];
setcookie('wochenendende', $end, 9999999999, '/');
} else {
$end = (($_COOKIE['wochenendende']) ? (int)$_COOKIE['wochenendende'] : 17);
}
// Die Ausgabe
echo $end;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment