I'm working on a CMS for display of articles, my problem is with the function strtotime()
does not indicate the correct date, always indicates March 1, 1970. A row (phpMyAdmin) of the article_timestamp
is given with the format: ex. 1394220287
. What am I doing wrong?
<span id="date">Publicado
<?php
setlocale(LC_ALL, NULL);
date_default_timezone_set('Europe/Lisbon');
$timeStamp = $article['article_timestamp'];
$uppercaseMonth = ucfirst(gmstrftime('%B'));
echo strftime( '%A, %d de ' .$uppercaseMonth. ' de %Y', strtotime($timeStamp));
?></span>