Problem/Motivation
In #3413726: Date values should be in RFC-822 format, not RFC-2822 RFC-822 format was adopted. However the way it is currently implemented, through the rfc822 Drupal date format, means the day and month parts get translated to the current site's language, which may cause issues. This can easily be fixed, by using the "r" format through the admin UI. However views_rss_format_date() hardcodes the use of \DateTimeInterface::RFC822.
Furthermore, the generated pubDate elements currently do not pass validation through tools such as https://validator.w3.org/feed/.
Steps to reproduce
Configure a view to use the "Advanced RSS feed" display format and add a field to use as the pubDate element.
Proposed resolution
Rely on the DATE_RSS php constant in views_rss_format_date() https://www.php.net/manual/en/datetime.constants.php#constant.date-rss
Go back to using "r" as the format to use for individual fields, in order to avoid involuntary translation.
Remaining tasks
Create a MR with the proposed changes.
Review.
Merge.
User interface changes
N/a
API changes
N/a
Data model changes
N/a
Issue fork views_rss-3623932
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
idebr commented