From: joerg Date: Sat, 20 Dec 2008 23:20:08 +0000 (+0000) Subject: More django templates X-Git-Url: https://git.deb.at/w?a=commitdiff_plain;h=b9000d554a40e938f0a8cd16403676d59c01b674;p=deb%2Fhackedgotchi.git More django templates git-svn-id: svn+ssh://svn.debian.org/svn/planet-debian/trunk@1059 c2f067bf-98e0-425f-9c98-e76020cfa380 --- diff --git a/config/config.ini b/config/config.ini index af91b36..01a3324 100644 --- a/config/config.ini +++ b/config/config.ini @@ -43,7 +43,7 @@ log_level = DEBUG spider_threads = 15 # template_files: Space-separated list of output template files -template_files = templates/index.html.dj templates/atom.xml.dj templates/rss20.xml.tmpl templates/rss10.xml.tmpl templates/opml.xml.tmpl templates/foafroll.xml.tmpl +template_files = templates/index.html.dj templates/atom.xml.dj templates/rss20.xml.dj templates/rss10.xml.dj templates/opml.xml.dj templates/foafroll.xml.dj # The following provide defaults for each template: # items_per_page: How many items to put on each page diff --git a/config/config.ini.tmpl b/config/config.ini.tmpl index 54d836d..416ccf2 100644 --- a/config/config.ini.tmpl +++ b/config/config.ini.tmpl @@ -77,7 +77,7 @@ log_level = DEBUG spider_threads = 15 # template_files: Space-separated list of output template files -template_files = templates/index.html.dj templates/atom.xml.dj templates/rss20.xml.tmpl templates/rss10.xml.tmpl templates/opml.xml.tmpl templates/foafroll.xml.tmpl +template_files = templates/index.html.dj templates/atom.xml.dj templates/rss20.xml.dj templates/rss10.xml.dj templates/opml.xml.dj templates/foafroll.xml.dj # The following provide defaults for each template: # items_per_page: How many items to put on each page diff --git a/templates/atom.xml.tmpl b/templates/atom.xml.tmpl deleted file mode 100644 index 4448459..0000000 --- a/templates/atom.xml.tmpl +++ /dev/null @@ -1,62 +0,0 @@ - - - - <TMPL_VAR name> - "/> - "/> - - - - - - xml:lang=""> - xml:lang="<TMPL_VAR title_language>"</TMPL_IF>><TMPL_VAR title ESCAPE="HTML"> - "/> - - - xml:lang=""> - xml:lang=""> - - - - - - - - - - - - - - - - - - - - - <TMPL_VAR channel_title ESCAPE="HTML"> - - <TMPL_VAR channel_name ESCAPE="HTML"> - - - - - "/> - - - - - - - - - - - - - - - - diff --git a/templates/foafroll.xml.dj b/templates/foafroll.xml.dj new file mode 100644 index 0000000..211ba37 --- /dev/null +++ b/templates/foafroll.xml.dj @@ -0,0 +1,31 @@ + + + + {{ name }} + {{ link }} + + +{% for channel in Channels %} + + + {{ channel.name }} + + + {{ channel.title_plain }} + + + + + + + +{% endfor %} + + + diff --git a/templates/foafroll.xml.tmpl b/templates/foafroll.xml.tmpl deleted file mode 100644 index a78e3e8..0000000 --- a/templates/foafroll.xml.tmpl +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - " /> - - - - - - - "> - - - " /> - - - - - - - - - diff --git a/templates/opml.xml.dj b/templates/opml.xml.dj new file mode 100644 index 0000000..2cc3d38 --- /dev/null +++ b/templates/opml.xml.dj @@ -0,0 +1,14 @@ + + + + {{ name }} + {{ date_822 }} + {{ owner_name }} + {{ owner_email }} + + + +{% for channel in Channels %} + {% endfor %} + + diff --git a/templates/opml.xml.tmpl b/templates/opml.xml.tmpl deleted file mode 100644 index b56ee5f..0000000 --- a/templates/opml.xml.tmpl +++ /dev/null @@ -1,15 +0,0 @@ - - - - <TMPL_VAR name ESCAPE="HTML"> - - - - - - - - " xmlUrl="" title="" htmlUrl="" /> - - - diff --git a/templates/rss10.xml.dj b/templates/rss10.xml.dj new file mode 100644 index 0000000..99726ea --- /dev/null +++ b/templates/rss10.xml.dj @@ -0,0 +1,30 @@ + + + + {{ name }} + {{ link }} + {{ name }} - {{ link }} + + + {% for item in Items %} + {% endfor %} + + + + +{% for item in Items %} + + {{ item.channel_name }}>{% if item.title %}: {{ item.title_plain }}{% endif %} + {{ item.link }} + {% if item.content %} {{ item.content }} {% endif %} + {{ item.date_iso }} + {% firstof item.author_name item.channel_author_name item.channel_name %} + {% endfor %} + + diff --git a/templates/rss10.xml.tmpl b/templates/rss10.xml.tmpl deleted file mode 100644 index f4f01f3..0000000 --- a/templates/rss10.xml.tmpl +++ /dev/null @@ -1,37 +0,0 @@ - - -"> - <TMPL_VAR name ESCAPE="HTML"> - - - - - - - - " /> - - - - - - -"> - <TMPL_VAR channel_name ESCAPE="HTML"><TMPL_IF title>: <TMPL_VAR title_plain ESCAPE="HTML"></TMPL_IF> - - - - - - - - - - - - diff --git a/templates/rss20.xml.dj b/templates/rss20.xml.dj new file mode 100644 index 0000000..743f2eb --- /dev/null +++ b/templates/rss20.xml.dj @@ -0,0 +1,20 @@ + + + + + {{ name }} + {{ link }} + en + {{ name }} - {{ link }} + +{% for item in Items %} + + {{ item.channel_name }}>{% if item.title %}: {{ item.title_plain }}{% endif %} + {{ item.id }} + {{ item.link }} + {% if item.content %} {% if item.channel_face %} <img src="http://planet.debian.org/heads/{{ item.channel_face }}" width="{{ item.channel_facewidth }}" height="{{ item.channel_faceheight }}" alt="" align="right" style="float: right;"> {% endif %} {{ item.content }} {% endif %} + {{ item.date_822 }} +{% if item.author_email %} {% if item.author_name %} {{ item.author_email }} ({{ item.author_name }}) {% else %} {{ item.author_email }} {% endif %} {% endif %} + {% endfor %} + + diff --git a/templates/rss20.xml.tmpl b/templates/rss20.xml.tmpl deleted file mode 100644 index 3f3abcf..0000000 --- a/templates/rss20.xml.tmpl +++ /dev/null @@ -1,30 +0,0 @@ - - - - - <TMPL_VAR name> - - en - - - - - - <TMPL_VAR channel_name ESCAPE="HTML"><TMPL_IF title>: <TMPL_VAR title_plain ESCAPE="HTML"></TMPL_IF> - - - - <img src="http://planet.debian.org/heads/" width="" height="" alt="" align="right" style="float: right;"> - - - - - () - - - - - - - - -