Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php header("Content-type: text/xml");
- echo '<'.'?xml version="1.0" encoding="UTF-8"?'.'>'; ?>
- <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
- <channel>
- <title>Antribute.eu</title><!-- Feed Titel -->
- <language>de</language><!-- Language -->
- <link>http://antribute.eu</link><!-- Adresse woher der Feed kommt -->
- <description>Pay you Tribute to the Chaos ~ Next Generation beginn</description><!-- Beschreibung des Feeds -->
- <copyright>Copyright <?php date(y); ?> antribute.eu</copyright><!-- Copyright -->
- <?php
- include('config.php');
- $sql = "SELECT * FROM blog ORDER BY id DESC LIMIT 0, 5";
- mysql_query("SET NAMES 'utf8'");
- $entry = mysql_query($sql,$datenbank) or die(mysql_error());
- while($blog = mysql_fetch_object($entry))
- {
- $id = $blog->id;
- $autor = $blog->autor;
- $title = $blog->title;
- $news = $blog->text;
- $pubdate = strtotime($row['datum']);
- $pubdate = date(r, $pubdate);
- ?>
- <item>
- <title><?php echo $title; ?></title>
- <link>http://antribute.eu/?p=blog&mode=view&id=<?php echo $id; ?></link>
- <guid isPermaLink="false">http://antribute.eu/?p=blog&mode=view&id=<?php echo $id; ?></guid>
- <author><?php echo $autor; ?></author>
- <pubDate><?php echo $pubdate; ?></pubDate>
- <?php if(mb_strlen($news,'utf-8') > 200){$text = mb_substr($news,0,200,'utf-8');} ?>
- <description><![CDATA[ <?php echo $news; ?> ]]></description>
- </item>
- <?php } /* close while*/ ?>
- </channel>
- </rss>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement