Fix #872 remove CDATA from RSS/Atom feeds

This commit is contained in:
Kijin Sung 2017-07-10 22:35:23 +09:00
parent 4904ca5155
commit f7915f8204
5 changed files with 27 additions and 27 deletions

View file

@ -3,7 +3,7 @@
<feed xmlns="http://www.w3.org/2005/Atom">
<title type="text">{$info->title}</title>
<!--@if($info->description)-->
<subtitle type="html">{str_replace('\'', '&apos;', htmlspecialchars($info->description, ENT_COMPAT | ENT_HTML401, 'UTF-8', false))}</subtitle>
<subtitle type="html">{escape($info->description, false)}</subtitle>
<!--@end-->
<updated>{$info->date}</updated>
<id>{$info->id}</id>
@ -11,25 +11,25 @@
<link rel="self" type="application/atom+xml" href="{$info->id}"/>
<generator uri="https://www.xpressengine.com/">XpressEngine</generator>
<!--@foreach($document_list as $oDocument)--> <entry>
<title><![CDATA[{$oDocument->getTitleText()}]]></title>
<title>{$oDocument->getTitleText()}</title>
<id>{$oDocument->getPermanentUrl()}</id>
<published>{$oDocument->getRegdate('Y-m-d\TH:i:sP')}</published>
<updated>{zdate($oDocument->get('last_update'),'Y-m-d\TH:i:sP')}</updated>
<link rel="alternate" type="text/html" href="{$oDocument->getPermanentUrl()}"/>
<link rel="replies" type="text/html" href="{$oDocument->getPermanentUrl()}#comment"/>
<author>
<name><![CDATA[{str_replace('\'', '&apos;',$oDocument->getNickName())}]]></name>
<name>{str_replace('\'', '&apos;',$oDocument->getNickName())}</name>
<!--@if($oDocument->isExistsHomepage())-->
<uri>{$oDocument->getHomepageUrl()}</uri>
<!--@end-->
</author>
<!--@if($open_rss_config[$oDocument->get('module_srl')]=='Y')-->
<content type="html"><![CDATA[{$oDocument->getTransContent(false,false,true)}]]></content>
<content type="html">{$oDocument->getTransContent(false,false,true)}</content>
<!--@else-->
<summary type="text"><![CDATA[{$oDocument->getContentText(100)}]]></summary>
<summary type="text">{$oDocument->getContentText(100)}</summary>
<!--@end-->
<!--@foreach($oDocument->get('tag_list') as $tag)-->
<category term="{str_replace('\'', '&apos;', htmlspecialchars($tag, ENT_COMPAT | ENT_HTML401, 'UTF-8', false))}"/>
<category term="{escape($tag, false)}"/>
<!--@end-->
</entry>