I am getting timestamp (1370956788472) of my android message like this :
cursor.getString(cursor.getColumnIndex("date"))
And trying to convert this android timestamp using php date() function and I am getting wrong Date and Time
echo date('Y-m-d H:i:s','1370956788472');
Output : 1997-04-28 09:50:48
But It will display correct date and time if i remove last three character from timestamp (removed 472 from 1370956788472) :
echo date('Y-m-d H:i:s','1370956788');
output: 2013-06-11 13:19:48
What is wrong here and what should i do can I divide my android timestamp with 1000