The module uses a custom function _atom_timestamp2w3dtf() when it could just use the PHP-provided DATE_ATOM constant with gmdate(). Core uses gmdate in it's RSS feeds so it doesn't have to mess with timezones. Since the constant was included in PHP 5.1.1 and above, we can also define it ourself for users of PHP 5.1.0 and below. This would clean up a small, but significant amount of code, and helps make the date formatting code much clearer.

CommentFileSizeAuthor
#1 583106-atom-gmdate-D6.patch2.2 KBdave reid

Comments

dave reid’s picture

Status: Active » Needs review
StatusFileSize
new2.2 KB

Patch attached for review.

dave reid’s picture

Title: Use DATE_W3C instead of _atom_timestamp2w3dtf() » Use DATE_ATOM instead of _atom_timestamp2w3dtf()

Correcting title.

dave reid’s picture

Assigned: Unassigned » dave reid
Status: Needs review » Fixed

Committed to CVS HEAD and DRUPAL-6--1.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.