kpetsche20 Posted December 29, 2008 Share Posted December 29, 2008 I am trying to convert a timestamp into a readable date. This is the error I am getting Warning: date() expects parameter 2 to be long, string given in /home/snugcash/public_html/admin/listnews.php on line 66 Here's the code <td width="152" class="myaccount"><?=date("Y-m-d", $data['date']) ?></a></td> Link to comment https://forums.phpfreaks.com/topic/138691-solved-timestamp-conversion-error/ Share on other sites More sharing options...
awpti Posted December 29, 2008 Share Posted December 29, 2008 So, what is the content of $data['date']? It's obviously not what it expects. Link to comment https://forums.phpfreaks.com/topic/138691-solved-timestamp-conversion-error/#findComment-725121 Share on other sites More sharing options...
kpetsche20 Posted December 29, 2008 Author Share Posted December 29, 2008 it's a timestamp 1230520015 That error is showing up, but the date is also displaying, so I just need to get rid of the error Link to comment https://forums.phpfreaks.com/topic/138691-solved-timestamp-conversion-error/#findComment-725123 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.