This question is an exact duplicate of:
Right, probably an easy one, but im having a blond moment and scratching my head.
date_default_timezone_set('Europe/London');
$today = date('d-m');
if(($today >= '01-11') && ($today <= '20-11'))
{
echo "<p class='rememberance'> </p>";
}
elseif (($today >= '2-12') && ($today <= '25-12'))
{
echo "<p class='christmas'> </p>";
}
elseif (($today >= '01-01') && ($today <= '09-01'))
{
echo "<p class='new-year'> </p>";
}
elseif (($today >= '01-04') && ($today <= '19-04'))
{
echo "<p class='easter'> </p>";
}
elseif (($today >= '01-06') && ($today <= '19-07'))
{
echo "<p class='yearend'> </p>";
}
else
{
echo "<p class='normal'> </p>";
}
I have some CSS rules set to display a little image based on the banding that the php outputs, now currently it is only showing the rememberance class! Can anyone help!!? Cheers
Aucun commentaire:
Enregistrer un commentaire