Thu Nov 27, 2008 4:42 pm
<?php
// include class
include ("Date.php");
// initialize object
$d = new Date("2008-10-03 16:23:48");
// set server time zone
$d->setTZByID("GMT");
// print server time
echo "Local time is " . $d->format("%A, %d %B %Y %T") . "\n";
// convert to IST
$d->convertTZByID("PST");
// output converted date/time
echo "Destination time is " . $d->format("%A, %d %B %Y %T");
?>
Codemiles.com is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to Amazon.com
Powered by phpBB © phpBB Group.