I have to insert the current date & time into my database table in order to track users "when was their last visit".
Currently I am in India. In my windows system, its showing 5/13/2013 5:58 Pm
But the below code is showing me the today data & time as 2013-05-13 13:02:28. Why time is not accurate.
I want to make the timing accurate for all users around the world.
I used the below code. Please help me to find this answer.
$datestring = "%Y-%m-%d: %d:%h:%i";
$time = time();
$today = mdate($datestring, $time);
echo ($today); //showing not accurate time, as I explained it above