A new Riff-radio.org site with a static approach.

post.tmpl 2.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. ## -*- coding: utf-8 -*-
  2. <%namespace name="helper" file="post_helper.tmpl"/>
  3. <%namespace name="pheader" file="post_header.tmpl"/>
  4. <%namespace name="comments" file="comments_helper.tmpl"/>
  5. <%namespace name="math" file="math_helper.tmpl"/>
  6. <%inherit file="base.tmpl"/>
  7. <%block name="extra_head">
  8. ${parent.extra_head()}
  9. % if post.meta('keywords'):
  10. <meta name="keywords" content="${post.meta('keywords')|h}">
  11. % endif
  12. %if post.description():
  13. <meta name="description" itemprop="description" content="${post.description()}">
  14. %endif
  15. <meta name="author" content="${post.author()}">
  16. %if post.prev_post:
  17. <link rel="prev" href="${post.prev_post.permalink()}" title="${post.prev_post.title()|h}" type="text/html">
  18. %endif
  19. %if post.next_post:
  20. <link rel="next" href="${post.next_post.permalink()}" title="${post.next_post.title()|h}" type="text/html">
  21. %endif
  22. % if post.is_draft:
  23. <meta name="robots" content="noindex">
  24. % endif
  25. ${helper.open_graph_metadata(post)}
  26. ${helper.twitter_card_information(post)}
  27. ${helper.meta_translations(post)}
  28. ${math.math_styles_ifpost(post)}
  29. </%block>
  30. <%block name="content">
  31. <article class="post-${post.meta('type')} h-entry hentry postpage" itemscope="itemscope" itemtype="http://schema.org/Article">
  32. ${pheader.html_post_header()}
  33. <div class="e-content entry-content" itemprop="articleBody text">
  34. ${post.text()}
  35. </div>
  36. <aside class="postpromonav">
  37. <nav>
  38. ${helper.html_tags(post)}
  39. ${helper.html_pager(post)}
  40. </nav>
  41. </aside>
  42. % if not post.meta('nocomments') and site_has_comments:
  43. <section class="comments hidden-print">
  44. <h2>${messages("Comments")}</h2>
  45. ${comments.comment_form(post.permalink(absolute=True), post.title(), post._base_path)}
  46. </section>
  47. % endif
  48. ${math.math_scripts_ifpost(post)}
  49. </article>
  50. ${comments.comment_link_script()}
  51. </%block>
  52. <%block name="sourcelink">
  53. % if show_sourcelink:
  54. <a href="${post.source_link()}" class="blog-nav-item blog-nav-item-aside" id="sourcelink">${messages("Source")}</a>
  55. % endif
  56. </%block>