I know it's gonna sound you strange.. but it's happening..
I am trying mktime()
function to create a seconds string:
$time = mktime(21,0,0,3,29,2014);
echo date("d-M, h:i A", $time);
And then I add 21600 (6 Hours) seconds in it..
$newstr = $time+21600;
echo echo date("d-M, h:i A", $newstr);
I Expect this output:
29-Mar, 09:03 PM
30-Mar, 03:03 AM
But I am getting this:
29-Mar, 09:03 PM
30-Mar, 04:03 AM // It must be 03:03 AM
Any one knows what the problem is..? I am using xampp.