mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-06-02 04:15:05 +02:00
merge r8451 from branch 2.1 to trunk
bug 2094 fixed: correct date format for feedcreator git-svn-id: http://piwigo.org/svn/trunk@8452 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -38,9 +38,7 @@ include_once(PHPWG_ROOT_PATH.'include/functions_notification.inc.php');
|
|||||||
*/
|
*/
|
||||||
function datetime_to_ts($datetime)
|
function datetime_to_ts($datetime)
|
||||||
{
|
{
|
||||||
$date = strptime($datetime, '%Y-%m-%d %H:%M:%S');
|
return strtotime($datetime);
|
||||||
return mktime($date['tm_hour'], $date['tm_min'], $date['tm_sec'],
|
|
||||||
$date['tm_mon'], $date['tm_mday'], 1900+$date['tm_year']);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -136,7 +134,7 @@ if (!$image_only)
|
|||||||
$item->description.= '</ul>';
|
$item->description.= '</ul>';
|
||||||
$item->descriptionHtmlSyndicated = true;
|
$item->descriptionHtmlSyndicated = true;
|
||||||
|
|
||||||
$item->date = $dbnow;
|
$item->date = ts_to_iso8601(datetime_to_ts($dbnow));
|
||||||
$item->author = $conf['rss_feed_author'];
|
$item->author = $conf['rss_feed_author'];
|
||||||
$item->guid= sprintf('%s', $dbnow);;
|
$item->guid= sprintf('%s', $dbnow);;
|
||||||
|
|
||||||
@@ -188,7 +186,7 @@ foreach($dates as $date_detail)
|
|||||||
|
|
||||||
$item->descriptionHtmlSyndicated = true;
|
$item->descriptionHtmlSyndicated = true;
|
||||||
|
|
||||||
$item->date = $date;
|
$item->date = ts_to_iso8601(datetime_to_ts($date));
|
||||||
$item->author = $conf['rss_feed_author'];
|
$item->author = $conf['rss_feed_author'];
|
||||||
$item->guid= sprintf('%s', 'pics-'.$date);;
|
$item->guid= sprintf('%s', 'pics-'.$date);;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user