Thu, September 23, 2021
 
https://devcodepro.comdevcodepro
X
Home · Latest · Trends
1

Smarty XML / RSS example file

<?xml version="1.0" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>Site Name</title>
<description>Site Description</description>
<link>http://www.example.com</link>
{section name=foo loop=$foo}
<item>
<title>{$foo[foo].progname|stripslashes|replace:"'":''|replace:'"':''|escape:'htmlall':'UTF-8'|replace:'&':' '}</title>
<description>{$foo[foo].longdesc|htmlspecialchars_decode|strip_tags|escape|truncate:200}</description>
<link>http://www.example.com/article.php?id={$foo[foo].articleid}</link>
<guid>http://www.example.com/article.php?id={$foo[foo].articleid}</guid>
<pubDate>{$foo[foo].date|date_format:"%a, %e %b %Y %H:%M:%S"} GMT</pubDate>
</item>
{/section}
</channel>
</rss>
rated 1 times (1) (0)
comments: 0 / hits: 1630  / 4 years ago, fri, feb 9, 18, 06:41:38
More From » HTML, XML
 

Comments

There are no comments for this Snippet yet
Only authorized users can post. Please sign in first, or register a free account
 
Share
Posted
Nica Radi
Member since Oct 29, 2017
Total Code Snippets: 4
Total Comments: 1
Location: n/a
Nica Radi snippets
4 years ago, mon, dec 4, 17, 5:57:17
comments: 0 / hits: 1990
PHP
4 years ago, thu, dec 7, 17, 2:24:01
comments: 0 / hits: 1299
CSS
4 years ago, mon, feb 19, 18, 11:28:09
comments: 0 / hits: 1499