Developers

Template localization

Voog templates support basic internationalization (i18n) and localization (l10n) features, such as date formatting. For example, when sending dates to output, they can be filtered by using date filters (format_date) where month and day names will be translated to the same language that the current page is in.

Following languages are supported:

  • de - german
  • en - english
  • et - estonian
  • fi - finnish
  • fr - french
  • lv - latvian
  • nl - dutch
  • pt - portugese
  • ru - russian
  • da - danish

Built-in translations

Built-in translations that are available for the lc filter. Example usage:
{{ 'add_a_comment' | lc }}
  • add_a_comment - Add a comment
  • add_new_post - Add a new blog post
  • all_posts - All posts
  • author - Author
  • browse_by_tags - Browse by tags
  • comment - Comment
  • comments - Comments
  • comments_for_count - Comments
  • comment_author_blank - Name is empty!
  • comment_body_blank - Comment is empty!
  • comment_email_blank - E-mail is empty!
  • disable_lang_flags - Don't use flags
  • email - E-mail
  • email_wont_be_published - E-mail won't be published
  • enable_lang_flags - Use flags
  • filter_by_tags - Filter by tags
  • filter_posts - Filter posts
  • footer_login_link - Voog. Make a website.
  • latest_article - Latest article
  • latest_news - Latest news
  • menu - Menu
  • name - Name
  • newer - Newer
  • news - News
  • next - Next
  • no_comments - No comments
  • no_posts_tagged - There are no posts tagged.
  • older - Older
  • older_news - Archive
  • posts_tagged - Posts tagged
  • previous - Previous
  • read_more - Read more
  • search - Search
  • search_close - Close
  • search_noresults - Your search did not match any documents
  • search_this_site - Search this site
  • submit - Submit
  • submit_comment - Submit comment
  • tags - Tags:
  • title_goes_here - Title goes here
  • write_first_comment - Write first comment
Built-in translations that are available for the lcc filter that returns translation based on the provided number. Example usage:
{{ 'post_has_replies' | lcc: article.comments_count }}
  • post_has_replies
    • 0 - This post has no replies
    • 1 - This post has 1 reply
    • other - This post has %{count} replies
  • replies
    • 0 - No replies
    • 1 - 1 reply
    • other - %{count} replies