blog.templatetags package¶
Submodules¶
blog.templatetags.blog_extras module¶
Some custom templatetags simplifying article rendering in templates
Simple temlatetag to retrieve article’s content by slug. If article is django template, it’s content is rendered
Incluision tag that renders article content. Base template is ``blog/article_panel. Currently is basic bootstrap panel
This templatetag is used in
blog/article_list.html,blog/article_detail.html.Parameters: - slug (str) – article’s slug
- header_link (bool) – If
Truethen article header is a link toblog.views.ArticleDetail - show_creation_time (bool) – If
Truethen publication datetime is shown.
Returns: rendered article template
Simple temlatetag to retrieve article’s content by slug. If article is django template, it’s content is rendered
Templatetag that returns article (variable with all article data) by it’s slug.
Can be used in templates to manualy display article on a page
Parameters: slug (str) – Article’s slug Return Article: blog.models.Articleinstance