Small spelling fixes
[mygpo.git] / mygpo / publisher / templates / publisher / podcast.html
bloba6662cd7dad58ea256b1be0db9b4483aea41e34f
1 {% extends "base.html" %}
2 {% load i18n %}
3 {% load humanize %}
4 {% load podcasts %}
5 {% load charts %}
6 {% load pcharts %}
7 {% load static %}
8 {% load menu %}
9 {% load utils %}
10 {% block mainmenu %}{{ "/publisher/"|main_menu }}{% endblock %}
11 {% block sectionmenu %}{{ "/publisher/podcast/"|section_menu:podcast.title }}{% endblock %}
13 {% block title %}{{ podcast.title|default:"Unnamed Podcast"|striptags }}{% endblock %}
15 {% block head %}
16 {% if timeline_data %}
17 {{ timeline_data|timeline }}
18 {% endif %}
19 {% endblock %}
21 {% block header %}
22 {% if podcast.logo_url %}
23 <div id="podcastlogo">{{ podcast|podcast_logo_big }}</div>
24 {% endif %}
26 <h1>{% if podcast.title %}{{ podcast.title|striptags }}{% else %}{% trans "Unnamed Podcast" %}{%endif%} <small>{% trans "Publisher Pages" %}</small></h1>
27 <small class="description">
28 {% if podcast.author %}{% trans "by" %}
29 {{ podcast.author|striptags }}
30 {% endif %}
31 {% if podcast.twitter %}
32 <a href="https://twitter.com/{{ podcast.twitter|striptags }}"><i class="icon-twitter"></i></a>
33 {% endif %}&middot;
34 <a href="{{podcast.url}}" title="{% trans "Feed" %}">
35 <i class="icon-rss"></i>
36 </a>
37 {% if podcast.link %}&middot;
38 <a href="{{podcast.link}}" title="{% trans "Website" %}">
39 <i class="icon-external-link"></i>
40 </a>
41 {% endif %}
42 {% if podcast.subscriber_count %}&middot;
43 {{ podcast.subscriber_count }} {% trans "subscribers" %}
44 {% endif %}
45 </small>
47 <div class="description">
48 {% blocktrans with podcast.title as ptitle %}This is the publisher page of <strong>{{ ptitle }}</strong>. You can see some stats and provide additional data for the podcast page.{% endblocktrans %}
49 <a class="btn btn-default" href="{% podcast_link_target podcast %}">{% trans "Go to Podcast Page" %}</a>
50 </div>
51 {% endblock %}
54 {% block content %}
55 <h2>Podcast Data</h2>
56 <p>{% trans "The podcast information is regularly retrieved from the podcast feed" %}</p>
57 <pre><a href="{{ podcast.url }}">{{ podcast.url }}</a></pre>
59 <h3>{% trans "Timing" %}</h3>
60 <ul>
61 <li>{% trans "Last update:" %} {{ podcast.last_update|naturaltime }}</li>
62 <li>{% trans "Update interval:" %} {{ podcast.update_interval|hours_to_str }}</li>
63 <li>{% trans "Next update:" %} {{ podcast.next_update|naturaltime }}</li>
64 </ul>
66 <form class="form-inline" action="{% podcast_link_target podcast "podcast-publisher-update" %}" method="post">
67 {% csrf_token %}
68 <button class="btn btn-default" type="submit">{% trans "Update now" %}</button>
69 </form>
72 <h2>Additional Data</h2>
74 <form class="form-horizontal" action="{% podcast_link_target podcast "podcast-publisher-save" %}" method="post">
75 {% csrf_token %}
77 <div class="form-group">
78 <label class="col-lg-2 control-label" for="inputTwitter">
79 <i class="icon-twitter"></i> {% trans "Twitter" %}
80 </label>
82 <div class="input-group col-lg-10">
83 <span class="input-group-addon">@</span>
84 <input type="text" class="form-control" id="inputTwitter" name="twitter" placeholder="username" value="{{ podcast.twitter }}">
85 </div>
86 </div>
89 <div class="form-group">
90 <div class="col-lg-offset-2 col-lg-10">
91 <button type="submit" class="btn btn-default">{% trans "Save" %}</button>
92 </div>
93 </div>
95 </form>
97 <h2>{% trans "Feed Check" %}</h2>
99 <div class="panel-group" id="accordion">
100 <div class="panel panel-default">
101 <div class="panel-heading">
102 <h4 class="panel-title">
103 <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion" href="#collapseFlattr">
104 <i class="icon-check{% if not podcast.flattr_url %}-empty{% endif %}"></i>
105 {% trans "Flattr" %}
106 </a>
107 </h4>
108 </div>
110 <div id="collapseFlattr" class="panel-collapse collapse in">
111 <div class="panel-body">
113 {% blocktrans with site.domain as sitename %}{{ sitename }} supports <a href="https://flattr.com/">Flattr</a>. When you provide <a href="http://developers.flattr.net/feed/">payment URLs</a> in your podcast feed, your listeners can support you financially by flattring your content.{% endblocktrans %}
114 </p>
115 {% if podcast.flattr_url %}
116 <div class="alert alert-success">
117 {% blocktrans %} We discovered payment URLs in your pdocast feed. Your listeners can automatically flattr your content!{% endblocktrans %}
118 </div>
119 {% else %}
120 <div class="alert alert-warning">
121 {% blocktrans %}We did not find <a href="http://developers.flattr.net/feed/">payment URLs</a> in your podcast feed. Add them so your listeners can support you!</a>{% endblocktrans %}
122 </div>
123 {% endif %}
124 </div>
125 </div>
126 </div>
128 <div class="panel panel-default">
129 <div class="panel-heading">
130 <h4 class="panel-title">
131 <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion-check" href="#collapsePubSub">
132 <i class="icon-check{% if not pubsubscription %}-empty{% endif %}"></i>
133 {% trans "PubSubHubbub" %}
134 </a>
135 </h4>
136 </div>
139 <div id="collapsePubSub" class="panel-collapse collapse">
140 <div class="panel-body">
142 {% blocktrans with site.domain as sitename %}If you publish your podcast feed through a <a href="https://code.google.com/p/pubsubhubbub/">PubSubHubbu</a> hub, {{ sitename }} can immediatelly update your podcast when a new episode is released.{% endblocktrans %}
143 </p>
144 {% if pubsubscription and pubsubscription.mode == 'subscribe' %}
145 {% if pubsubscription.verified %}
146 <div class="alert alert-success">
147 {% blocktrans with podcast.hub as hub %}Your podcast is published through <a href="{{ hub }}">{{ hub }}</a> and should update immediatelly for each new episode.{% endblocktrans %}
148 </div>
149 {% else %}
150 <div class="alert alert-warning">
151 {% blocktrans with podcast.hub as hub %}Your podcast is published through <a href="{{ hub }}">{{ hub }}</a> but our subscription has not yet been verified.{% endblocktrans %}
152 </div>
153 {% endif %}
154 {% else %}
155 <div class="alert alert-warning">
156 {% blocktrans %}We did not find a hub in your podcast feed. Your feed is updated regularly, but there might be some delay until a new episode shows up on {{ sitename }}.{% endblocktrans %}
157 </div>
158 {% endif %}
159 </div>
160 </div>
161 </div>
163 <div class="panel panel-default">
164 <div class="panel-heading">
165 <h4 class="panel-title">
166 <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion-check" href="#collapseLicense">
167 <i class="icon-check{% if not podcast.license %}-empty{% endif %}"></i>
168 {% trans "License Information" %}
169 </a>
170 </h4>
171 </div>
173 <div id="collapseLicense" class="panel-collapse collapse">
174 <div class="panel-body">
176 {% blocktrans with site.domain as sitename %}You should include license information in your feed so that users and {{ sitename }} can know, under which conditions your content can be used.{% endblocktrans %}
177 </p>
178 {% if podcast.license %}
179 <div class="alert alert-success">
180 {% blocktrans with podcast.license as license %}We found the following license in your podcast: <a href="{{ license }}">{{ license }}</a>{% endblocktrans %}
181 </div>
182 {% else %}
183 <div class="alert alert-warning">
184 {% blocktrans %}We did not find a license in your podcast feed. Refer to <a href="https://github.com/gpodder/podcast-feed-best-practice/blob/master/podcast-feed-best-practice.md#license"> gPodder Podcast Feed Best Practice</a> on how to include license information.{% endblocktrans %}
185 </div>
186 {% endif %}
187 </div>
188 </div>
189 </div>
191 </div>
194 <h2>Episodes</h2>
195 <p>View and edit <a href="{% podcast_link_target podcast "podcast-publisher-episodes" %}">episode</a> data.</p>
198 <h2>{% trans "Link" %}</h2>
199 <p>{% blocktrans with url as sitename %}You can paste this code on your website, so users of {{ sitename }} can directly subscribe to your podcast.{% endblocktrans %}</p>
200 <textarea style="width: 100%;" rows="2"><a href="http://{{ site.domain }}{% url "subscribe-by-url" %}?url={{ feedurl_quoted }}"><img src="http://{{ site.domain }}{% static "author_subscribe.png" %}" /></a></textarea>
201 <p><a href="http://{{ site.domain }}{% url "subscribe-by-url" %}?url={{ feedurl_quoted }}"><img src="http://{{ site.domain }}{% static "author_subscribe.png" %}" /></a></p>
203 <h2>Stats</h2>
205 {% if group %}
206 <a href="{% podcast_group_link_target group "group-publisher" %}">{% trans "Show Group Stats" %}</a>
207 {% endif %}
209 {% if timeline_data %}
210 <h3>Listener Timeline</h3>
211 <div id="chart_div" style="width: 700px; height: 240px;"></div>
212 {% endif %}
215 {% if subscriber_data %}
216 <h3>Subscriptions</h3>
217 <p>Please note that the chart shows subscriptions per user and device, so a single user subscribing to this podcast on 5 devices acccounts for 5 subscriptions.</p>
218 {{ subscriber_data|bar_chart }}
219 {% endif %}
221 {% if heatmap %}
222 <h3>Heatmap</h3>
223 <div>
224 {% trans "This diagram shows which parts of the podcast's episodes are listened the most by users." %}
225 {% trans "Red parts are often skipped, green parts never." %}
226 </div>
227 {{ heatmap|episode_heatmap_visualization }}
228 {% endif %}
230 {% endblock %}