summaryrefslogtreecommitdiff
path: root/templates/news
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2013-04-21 02:22:44 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2013-04-21 02:22:44 -0400
commit03fa7e4f27bdb39a8f8f5ed91a87d18bf8357b47 (patch)
treec67eafcbda55706f18400b3115a2b8a5be318394 /templates/news
parent91c451821ce7000cbc268cec8427d208a6cedd7e (diff)
parentb8ee7b1ee281b45b245fb454228b8ad847c56200 (diff)
Merge branch 'archweb' into archweb-generic2
Conflicts: devel/views.py feeds.py public/views.py settings.py sitestatic/archweb.js templates/base.html templates/devel/profile.html templates/mirrors/status.html templates/news/view.html templates/packages/flaghelp.html templates/packages/opensearch.xml templates/public/download.html templates/public/feeds.html templates/public/index.html templates/registration/login.html templates/releng/results.html templates/todolists/public_list.html
Diffstat (limited to 'templates/news')
-rw-r--r--templates/news/list.html4
-rw-r--r--templates/news/paginator.html10
-rw-r--r--templates/news/view.html20
3 files changed, 23 insertions, 11 deletions
diff --git a/templates/news/list.html b/templates/news/list.html
index 98cf9a73..0ddf3b5e 100644
--- a/templates/news/list.html
+++ b/templates/news/list.html
@@ -1,6 +1,10 @@
{% extends "base.html" %}
{% block title %}{{ BRANDING_DISTRONAME }} - News{% endblock %}
+{% block head %}
+<link rel="alternate" type="application/rss+xml" title="Arch Linux News Updates" href="/feeds/news/" />
+{% endblock %}
+
{% block content %}
<div id="news-article-list" class="box">
diff --git a/templates/news/paginator.html b/templates/news/paginator.html
index fbd0546b..57fbeb15 100644
--- a/templates/news/paginator.html
+++ b/templates/news/paginator.html
@@ -1,20 +1,20 @@
{% if is_paginated %}
<div class="pagination">
- <p>{{paginator.count}} news items, viewing page {{page_obj.number}} of {{paginator.num_pages}}.</p>
+ <p>{{ paginator.count }} news items, viewing page {{ page_obj.number }} of {{ paginator.num_pages }}.</p>
<p class="news-nav">
{% if page_obj.has_previous %}
- <a class="prev" href="?page={{page_obj.previous_page_number}}"
+ <a class="prev" href="?page={{ page_obj.previous_page_number }}"
title="Go to previous page">&lt; Prev</a>
{% endif %}
{% for num in paginator.page_range %}
{% ifequal num page_obj.number %}
- <span>{{num}}</span>
+ <span>{{ num }}</span>
{% else %}
- <a href="?page={{num}}" title="Go to page {{num}}">{{num}}</a>
+ <a href="?page={{ num }}" title="Go to page {{ num }}">{{ num }}</a>
{% endifequal %}
{% endfor %}
{% if page_obj.has_next %}
- <a class="next" href="?page={{page_obj.next_page_number}}"
+ <a class="next" href="?page={{ page_obj.next_page_number }}"
title="Go to next page">Next &gt;</a>
{% endif %}
</p>
diff --git a/templates/news/view.html b/templates/news/view.html
index 47830867..93cf32d4 100644
--- a/templates/news/view.html
+++ b/templates/news/view.html
@@ -1,11 +1,20 @@
{% extends "base.html" %}
-{% load markup %}
{% block title %}{{ BRANDING_DISTRONAME }} - News: {{ news.title }}{% endblock %}
{% block content %}
-<div class="news-article box">
-
- <h2>News: {{ news.title }}</h2>
+<div itemscope itemtype="http://schema.org/Article" class="news-article box">
+ <h2 itemprop="headline">{{ news.title }}</h2>
+ <meta itemprop="dateCreated" content="{{ news.postdate|date:"Y-m-d" }}"/>
+ <meta itemprop="datePublished" content="{{ news.postdate|date:"Y-m-d" }}"/>
+ <meta itemprop="dateModified" content="{{ news.last_modified|date:"Y-m-d" }}"/>
+ <meta itemprop="inLanguage" content="en"/>
+ <meta itemprop="wordCount" content="{{ news.content|wordcount }}"/>
+ <div style="display:none" itemprop="author" itemscope itemtype="http://schema.org/Person">
+ <meta itemprop="name" content="{{ news.author.get_full_name|escape }}"/>
+ </div>
+ <div style="display:none" itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
+ <meta itemprop="name" content="{{ BRANDING_DISTRONAME }}"/>
+ </div>
{% if perms.news.change_news %}
<ul class="admin-actions">
@@ -18,7 +27,6 @@
<p class="article-info">{{ news.postdate|date }} - {{ news.author.get_full_name }}</p>
- <div class="article-content">{{ news.content|markdown }}</div>
-
+ <div class="article-content" itemprop="articleBody">{{ news.html }}</div>
</div>
{% endblock %}