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

post.tmpl 1.9KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  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. <meta name="author" content="${post.author()|h}">
  13. %if post.prev_post:
  14. <link rel="prev" href="${post.prev_post.permalink()}" title="${post.prev_post.title()|h}" type="text/html">
  15. %endif
  16. %if post.next_post:
  17. <link rel="next" href="${post.next_post.permalink()}" title="${post.next_post.title()|h}" type="text/html">
  18. %endif
  19. % if post.is_draft:
  20. <meta name="robots" content="noindex">
  21. % endif
  22. ${helper.open_graph_metadata(post)}
  23. ${helper.twitter_card_information(post)}
  24. ${helper.meta_translations(post)}
  25. ${math.math_styles_ifpost(post)}
  26. </%block>
  27. <%block name="content">
  28. <article class="post-${post.meta('type')} h-entry hentry postpage" itemscope="itemscope" itemtype="http://schema.org/Article">
  29. ${pheader.html_post_header()}
  30. <div class="e-content entry-content" itemprop="articleBody text">
  31. ${post.text()}
  32. </div>
  33. <aside class="postpromonav">
  34. <nav>
  35. ${helper.html_tags(post)}
  36. ${helper.html_pager(post)}
  37. </nav>
  38. </aside>
  39. % if not post.meta('nocomments') and site_has_comments:
  40. <section class="comments hidden-print">
  41. <h2>${messages("Comments")}</h2>
  42. ${comments.comment_form(post.permalink(absolute=True), post.title(), post._base_path)}
  43. </section>
  44. % endif
  45. ${math.math_scripts_ifpost(post)}
  46. </article>
  47. ${comments.comment_link_script()}
  48. </%block>
  49. <%block name="sourcelink">
  50. % if show_sourcelink:
  51. <li>
  52. <a href="${post.source_link()}" id="sourcelink">${messages("Source")}</a>
  53. </li>
  54. % endif
  55. </%block>