You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
In RSS/Atom feed [category] view (with url - /?format=feed&type=atom), in xml, item creation date is used for <pubDate> / <published> tag instead of publish date. Why? Sorting of the items is still displayed by date of publication, as my blog category view sorting settings.
Describe the solution you'd like
So, I edited \Joomla\CMS\MVC\View\CategoryFeedView , for Joomla 3.8.10 - /libraries/src/MVC/View/CategoryFeedView.php, on line :100,
replace:
if ($createdField)
with:
if (isset($item->publish_up)) { $date = date('r', strtotime($item->publish_up)); } elseif ($createdField)
Additional context
But with my code meaning of $createdField is ignored ($date = isset($item->$createdField) ? date('r', strtotime($item->$createdField)) : '';). So. my code is only workaround for my problem.
P.s. sorry for my English
The text was updated successfully, but these errors were encountered:
AndNovAtor
changed the title
In CategoryFeedView - use article [item] publish date instead of creation date for... <pubDate> / <published>
In CategoryFeedView - use article [item] publish date instead of creation date for RSS / ATOM... <pubDate> / <published>
Jun 27, 2018
joomla-cms-bot
changed the title
In CategoryFeedView - use article [item] publish date instead of creation date for RSS / ATOM... <pubDate> / <published>
In CategoryFeedView - use article [item] publish date instead of creation date for RSS / ATOM... /
Jun 27, 2018
So, what's Joomlas's opinion on this? Because Joomlas's publish up article date can be used for creating news "from the past" (for example, when I migrate news to the new site version and want to "save" RSS from the old site version).
Btw, RSS specification "says":
pubDate The publication date for the content in the channel
Is your feature request related to a problem? Please describe.
In RSS/Atom feed [category] view (with url -
/?format=feed&type=atom
), in xml, item creation date is used for<pubDate>
/<published>
tag instead of publish date. Why? Sorting of the items is still displayed by date of publication, as my blog category view sorting settings.Describe the solution you'd like
So, I edited
\Joomla\CMS\MVC\View\CategoryFeedView
, for Joomla 3.8.10 -/libraries/src/MVC/View/CategoryFeedView.php
, on line:100
,replace:
if ($createdField)
with:
if (isset($item->publish_up)) { $date = date('r', strtotime($item->publish_up)); } elseif ($createdField)
Additional context
But with my code meaning of $createdField is ignored (
$date = isset($item->$createdField) ? date('r', strtotime($item->$createdField)) : '';
). So. my code is only workaround for my problem.P.s. sorry for my English
The text was updated successfully, but these errors were encountered: