aboutsummaryrefslogtreecommitdiffstats
path: root/photowall/templates/article.html
blob: e321137d66b36fbd5fbb3a6febc4655c980a4432 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
{% extends "base.html" %}
{% block title %}{{ article.title|striptags }}{% endblock %}
{% block content %}
<section id="pagecontent" class="body">
	<script>
	Mousetrap.bind('left', prev);
	Mousetrap.bind('right', next);


	function prev(element)
	{
		document.getElementById('prev').click();
	}
	function next(element)
	{
		document.getElementById('next').click();
	}
	</script>
  <article>
    <header>
	<div>
		<div style="float:left">
		      <h1 class="entry-title">
		        <a href="{{ SITEURL }}/{{ article.url }}" rel="bookmark"
		           title="Permalink to {{ article.title|striptags }}">{{ article.title }}</a>
		      </h1>
		</div>
		<div style="float:right"><h2>{% include 'article_infos.html' %}</h2></div>
	</div>

	<div style="clear:both"></div>

 {% if article.prev_article %}
	<div style="float:left">
         <a href="{{ SITEURL }}/{{ article.prev_article.url}}" id="prev">
             Previous: {{ article.prev_article.title }}
         </a>
	</div>
 {% endif %}
 {% if article.next_article %}
	<div style="float:right">
         <a href="{{ SITEURL }}/{{ article.next_article.url}}" id="next">
             Next: {{ article.next_article.title }}
         </a>
	</div>
 {% endif %}
      {% include 'twitter.html' %}
    </header>
      {{ article.content }}

    {% if DISQUS_SITENAME and SITEURL and article.status != "draft" %}
    <div class="comments">
      <h2>Comments !</h2>
      <div id="disqus_thread"></div>
      <script type="text/javascript">
        var disqus_shortname = '{{ DISQUS_SITENAME }}';
        var disqus_identifier = '{{ article.url }}';
        var disqus_url = '{{ SITEURL }}/{{ article.url }}';
        (function() {
        var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
        dsq.src = 'https://{{ DISQUS_SITENAME }}.disqus.com/embed.js';
        (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
        })();
      </script>
      <noscript>Please enable JavaScript to view the comments.</noscript>
    </div>
    {% endif %}

  </article>
</section>
{% endblock %}