diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2009-02-25 15:39:21 -0500 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2009-02-25 15:39:21 -0500 |
commit | 4cce41c058cc132df28c891585a8380a68f6ab23 (patch) | |
tree | 2b6a98b7b44728a1692a3fff2cc4893a8a038e8a /rss.php | |
parent | 9f112c2e1668c286bdbf832f6e2f4451b7d52b44 (diff) | |
download | pillowcase-4cce41c058cc132df28c891585a8380a68f6ab23.tar.gz pillowcase-4cce41c058cc132df28c891585a8380a68f6ab23.tar.bz2 pillowcase-4cce41c058cc132df28c891585a8380a68f6ab23.zip |
Added RSS feed
Diffstat (limited to 'rss.php')
-rw-r--r-- | rss.php | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/rss.php b/rss.php new file mode 100644 index 0000000..4b710aa --- /dev/null +++ b/rss.php | |||
@@ -0,0 +1,33 @@ | |||
1 | <?php | ||
2 | |||
3 | include('includes/db.php'); | ||
4 | include('includes/update.php'); | ||
5 | |||
6 | echo('<?xml version="1.0"?>'); | ||
7 | |||
8 | ?> | ||
9 | <rss version="2.0"> | ||
10 | <channel> | ||
11 | <title>Pillowcase</title> | ||
12 | <link>http://pillowcase.fourisland.com/</link> | ||
13 | <description>pillowcase - the result of an obsession with cute, plush objects that talk nonsense</description> | ||
14 | <language>en-us</language> | ||
15 | <?php | ||
16 | |||
17 | $getitems = "SELECT * FROM comics WHERE status = \"publish\" ORDER BY comic_id DESC LIMIT 0,10"; | ||
18 | $getitems2 = mysql_query($getitems); | ||
19 | while ($getitems3 = mysql_fetch_array($getitems2)) | ||
20 | { | ||
21 | ?> | ||
22 | <item> | ||
23 | <title><?php echo($getitems3['title']); ?></title> | ||
24 | <link>http://pillowcase.fourisland.com/comic<?php echo($getitems3['comic_id']); ?>.htm</link> | ||
25 | <description><![CDATA[<IMG SRC="http://pillowcase.fourisland.com/images/comics/<?php echo($getitems3['filename']); ?> ALT="<?php echo($getitems3['title']); ?>"><p><?php echo($getitems3['text']); ?></p>]]></description> | ||
26 | <pubDate><?php echo(date('D, d M Y H:i:s O',strtotime($getitems3['pubDate']))); ?></pubDate> | ||
27 | </item> | ||
28 | <?php | ||
29 | } | ||
30 | |||
31 | ?> | ||
32 | </channel> | ||
33 | </rss> | ||