Skip to content

Commit

Permalink
Merge pull request #44 from pascalchevrel/feeds
Browse files Browse the repository at this point in the history
Feeds
  • Loading branch information
mauricesvay committed May 5, 2012
2 parents c6153c7 + 107fd72 commit 0649e75
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions custom/views/atom10/index.tpl.php
Expand Up @@ -5,8 +5,8 @@
header('Content-Type: application/atom+xml; charset=UTF-8');
echo '<?xml version="1.0" encoding="UTF-8" ?>';
?><feed xmlns="http://www.w3.org/2005/Atom">
<title><?php echo htmlentities($PlanetConfig->getName()); ?></title>
<subtitle></subtitle>
<title><?php echo htmlspecialchars($PlanetConfig->getName()); ?></title>
<subtitle><?php echo htmlspecialchars($PlanetConfig->getName()); ?></subtitle>
<id><?php echo $PlanetConfig->getUrl(); ?></id>
<link rel="self" type="text/html" href="<?php echo $PlanetConfig->getUrl(); ?>?type=atom10" />
<link rel="alternate" type="text/html" href="<?php echo $PlanetConfig->getUrl(); ?>" />
Expand All @@ -15,11 +15,12 @@

<?php $count = 0; ?>
<?php foreach ($items as $item): ?>
<entry xmlns="http://www.w3.org/2005/Atom">
<entry>
<title type="html"><?php echo htmlspecialchars($item->get_feed()->getName()); ?> : <?php echo htmlspecialchars($item->get_title());?></title>
<id><?php echo htmlspecialchars($item->get_permalink());?></id>
<link rel="alternate" href="<?php echo htmlspecialchars($item->get_permalink());?>"/>
<published><?php echo $item->get_date('Y-m-d\\TH:i:s+00:00'); ?></published>
<updated><?php echo $item->get_date('Y-m-d\\TH:i:s+00:00'); ?></updated>
<author><name><?php echo ($item->get_author()? $item->get_author()->get_name() : 'anonymous'); ?></name></author>

<content type="html"><![CDATA[<?php echo $item->get_content();?>]]></content>
Expand Down

0 comments on commit 0649e75

Please sign in to comment.