PHP: [ Select all ]
// ################### APRIL FOOLS DAY #####################
global $userinfo;
$cookietime = 5; //Time between popups. In minutes. Set to 0 for no time between message showing up on page refreshes
$cookie_name = 'april_fool_hsx'; //Cookie Name
$cookie_value = 'true';
// $uname2 = $userinfo['username']; //Only used if you want to target specific people or only your self for testing purposes
$afdate = date("md"); //Check to see if today is April Fools day
//############################################################
if (!isset($_COOKIE['april_fool_hsx']) /*&& $uname2 == 'coRpSE' */&& $afdate == '0401'){
echo "<link rel=\"stylesheet\" href=\"./PATH_TO_CSS/af-css.css\" type=\"text/css\">";
echo '<audio autoplay loop> <source src="./includes/ap/rick-rolled.mp3" type="audio/mpeg"> Your browser does not support the audio element.</audio>';
echo '<div class="afbanner"> </div>';
//create cookie
setcookie($cookie_name, $cookie_value, time() + (60 * $cookietime), "/" );
//cookie created
}
// ################### END APRIL FOOLS ######################