Created
July 27, 2013 23:10
-
-
Save blackymetal/6096655 to your computer and use it in GitHub Desktop.
CakePHP adding atom:link to channel using RSS Helper
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$this->set('documentData', array('xmlns:dc' => 'http://purl.org/dc/elements/1.1/', 'xmlns:atom' => 'http://www.w3.org/2005/Atom')); | |
$this->set('channelData', array( | |
'title' => __("Comercio Exterior", true), | |
'link' => 'http://www.aduanacol.com/news.rss', | |
'description' => __("Noticias más recientes de comercio exterior Colombiano.", true), | |
'language' => 'es-co', | |
'atom:link' => array( | |
'attrib' => array( | |
'href' => 'http://www.aduanacol.com/news.rss', | |
'rel' => 'self', | |
'type' => 'application/rss+xml' | |
) | |
) | |
)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks ! It works very well.
And you can just replace
'href' => 'http://www.aduanacol.com/news.rss',
with
'href' => $this->Html->url('/news.rss', true),