1
0
Fork 0
forked from blallo/rss-bridge

fix AtomFormat elements escaping

This commit is contained in:
Mitsukarenai 2014-10-27 15:16:39 +01:00
parent 5f64a2531d
commit 119c30b999

View file

@ -22,9 +22,9 @@ class AtomFormat extends FormatAbstract{
$entries = ''; $entries = '';
foreach($this->getDatas() as $data){ foreach($this->getDatas() as $data){
$entryName = htmlspecialchars(is_null($data->name) ? $title : $data->name); $entryName = strip_tags(is_null($data->name) ? $title : $data->name);
$entryAuthor = htmlspecialchars(is_null($data->author) ? $uri : $data->author); $entryAuthor = strip_tags(is_null($data->author) ? $uri : $data->author);
$entryTitle = htmlspecialchars(is_null($data->title) ? '' : $data->title); $entryTitle = strip_tags(is_null($data->title) ? '' : $data->title);
$entryUri = htmlspecialchars(is_null($data->uri) ? '' : $data->uri); $entryUri = htmlspecialchars(is_null($data->uri) ? '' : $data->uri);
$entryTimestamp = is_null($data->timestamp) ? '' : date(DATE_ATOM, $data->timestamp); $entryTimestamp = is_null($data->timestamp) ? '' : date(DATE_ATOM, $data->timestamp);
// We prevent content from closing the CDATA too early. // We prevent content from closing the CDATA too early.