summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2016-12-27 14:44:39 +0100
committeremkael <emkael@tlen.pl>2016-12-27 14:44:39 +0100
commit59bd9d51cc705dd44bdce753a56cc6ae914b02ce (patch)
treed61f42dccd15b1b630204c1575b4dedc1c98e9cf /templates
parentb76bf844db1f196e3fa709461fcb4706839744e5 (diff)
* directory structure
Diffstat (limited to 'templates')
-rw-r--r--templates/.htaccess1
-rw-r--r--templates/atom.tpl21
-rw-r--r--templates/rss.tpl19
3 files changed, 41 insertions, 0 deletions
diff --git a/templates/.htaccess b/templates/.htaccess
new file mode 100644
index 0000000..3a42882
--- /dev/null
+++ b/templates/.htaccess
@@ -0,0 +1 @@
+Deny from all
diff --git a/templates/atom.tpl b/templates/atom.tpl
new file mode 100644
index 0000000..e7e28f5
--- /dev/null
+++ b/templates/atom.tpl
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<feed xmlns="http://www.w3.org/2005/Atom">
+ <title>{$user}'s timeline</title>
+ <link href="https://twitter.com/{$user}" />
+ <id>http://emkael.info/tulz/twitterRSS/{$user}</id>
+ <updated>{$cacheTime|date_format:"c"}</updated>
+ {foreach from=$content item=item}
+ <entry>
+ <title>{$item->text|escape}</title>
+ <link href="https://twitter.com/{$user}/status/{$item->id_str}" />
+ <id>http://emkael.info/tulz/twitterRSS/{$item->user->id_str}/{$item->id_str}</id>
+ <updated>{$item->created_at|date_format:"c"}</updated>
+ <summary><![CDATA[ {$item->text|escape} ]]></summary>
+ {if isset($item->user)}
+ <author>
+ <name>{$item->user->screen_name}</name>
+ </author>
+ {/if}
+ </entry>
+ {/foreach}
+</feed>
diff --git a/templates/rss.tpl b/templates/rss.tpl
new file mode 100644
index 0000000..f95a462
--- /dev/null
+++ b/templates/rss.tpl
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<rss version="2.0">
+ <channel>
+ <title>{$user}'s timeline</title>
+ <link>https://twitter.com/{$user}</link>
+ <lastBuildDate>{$cacheTime|date_format:"D, d M Y H:i:s O"}</lastBuildDate>
+ {foreach from=$content item=item}
+ <item>
+ <title>{$item->text|escape}</title>
+ <link>https://twitter.com/{$user}/status/{$item->id_str}</link>
+ {if isset($item->user)}
+ <guid>http://emkael.info/tulz/twitterRSS/{$item->user->id_str}/{$item->id_str}</guid>
+ {/if}
+ <description><![CDATA[ {$item->text|escape} ]]></description>
+ <pubDate>{$item->created_at|date_format:"D, d M Y H:i:s O"}</pubDate>
+ </item>
+ {/foreach}
+ </channel>
+</rss>