mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-07-24 04:34:56 +02:00
formats: Use same general entity generation order
This commit is contained in:
parent
0d94f1fe0e
commit
606e756bc1
3 changed files with 6 additions and 10 deletions
|
@ -23,13 +23,11 @@ class AtomFormat extends FormatAbstract{
|
|||
|
||||
$entries = '';
|
||||
foreach($this->getDatas() as $data){
|
||||
$entryAuthor = is_null($data->author) ? $title : $this->xml_encode($data->author);
|
||||
$entryAuthor = is_null($data->author) ? '' : $this->xml_encode($data->author);
|
||||
$entryTitle = is_null($data->title) ? '' : $this->xml_encode($data->title);
|
||||
$entryUri = is_null($data->uri) ? '' : $this->xml_encode($data->uri);
|
||||
$entryTimestamp = is_null($data->timestamp) ? '' : $this->xml_encode(date(DATE_ATOM, $data->timestamp));
|
||||
// We prevent content from closing the CDATA too early.
|
||||
$entryContent = is_null($data->content) ? '' : $this->xml_encode($this->sanitizeHtml($data->content));
|
||||
|
||||
$entries .= <<<EOD
|
||||
|
||||
<entry>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue