Hi,
I found a nice piece of code for the date and time and it allows for daylight savings, I have been using this code for a while and i've never had any error messages but for some reason I get a error message now but the function still does what it should.
can anyone see what the problem is?
this is the output from the php page
and this is the code
I found a nice piece of code for the date and time and it allows for daylight savings, I have been using this code for a while and i've never had any error messages but for some reason I get a error message now but the function still does what it should.
can anyone see what the problem is?
this is the output from the php page
Warning: Missing argument 3 for zonedate(), called in /home/veresour/public_html/streammii.com/q/dateTest.php on line 17 and defined in /home/veresour/public_html/streammii.com/q/dateTest.php on line 2
Warning: Missing argument 4 for zonedate(), called in /home/veresour/public_html/streammii.com/q/dateTest.php on line 17 and defined in /home/veresour/public_html/streammii.com/q/dateTest.php on line 2
16 Jul 2010 11:52:54
Warning: Missing argument 4 for zonedate(), called in /home/veresour/public_html/streammii.com/q/dateTest.php on line 17 and defined in /home/veresour/public_html/streammii.com/q/dateTest.php on line 2
16 Jul 2010 11:52:54
Code:
<?
function zonedate($layout, $countryzone, $daylightsaving, $time)
{
if($daylightsaving) {
$daylight_saving = date('I');
if($daylight_saving){ $zone=3600*($countryzone+1); }
}
else {
if( $countryzone>>0){ $zone=3600*$countryzone; }
else { $zone=0; }
}
if(!$time) { $time = time(); }
$date = gmdate($layout, $time + $zone);
return $date;
}
$dateAdded = zonedate('d M Y H:i:s',true);
echo '<br/>'.$dateAdded;
?>
Comment