Jump to content

date_default_timezone_set


sepoto

Recommended Posts

I am wondering why the error below is coming up. I have attached my snippet as well. I can't seem to figure this out.

Notice: date_default_timezone_set() [function.date-default-timezone-set]: Timezone ID 'PST' is invalid in C:\inetpub\wwwroot\dsgog\guide.php on line 27

//Set up the timezone array$TZ = array("PST" => -800,			"EST" => -500,			"CST" => -600,			"MST" => -700,			"PST-2" => -1000,			"PST-1" => -900);//Get the user's timezone info and if DST$sql = "select * from zip_timezone where zip = {$_SESSION['zip']}";$res = $db->query($sql);$row = $res->fetch_assoc();$timezone = $row['TZ'];$tz_offset = $TZ[$timezone];if($row['DST'] == "Y")  $tz_offset = (int)$tz_offset + 100;date_default_timezone_set('PST');

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...