Skip to content

Commit

Permalink
Closes #2835 w3c validation warning/error with dates in feeds
Browse files Browse the repository at this point in the history
  • Loading branch information
glamorous authored and Woody Gilk committed May 25, 2010
1 parent 1557b3e commit be5f6ef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions classes/kohana/feed.php
Expand Up @@ -80,7 +80,7 @@ public static function create($info, $items, $format = 'rss2', $encoding = 'UTF-
if (($name === 'pubDate' OR $name === 'lastBuildDate') AND (is_int($value) OR ctype_digit($value)))
{
// Convert timestamps to RFC 822 formatted dates
$value = date(DATE_RFC822, $value);
$value = date('r', $value);
}
elseif (($name === 'link' OR $name === 'docs') AND strpos($value, '://') === FALSE)
{
Expand All @@ -102,7 +102,7 @@ public static function create($info, $items, $format = 'rss2', $encoding = 'UTF-
if ($name === 'pubDate' AND (is_int($value) OR ctype_digit($value)))
{
// Convert timestamps to RFC 822 formatted dates
$value = date(DATE_RFC822, $value);
$value = date('r', $value);
}
elseif (($name === 'link' OR $name === 'guid') AND strpos($value, '://') === FALSE)
{
Expand Down

0 comments on commit be5f6ef

Please sign in to comment.