Reference

blog

title

Your site’s title, set on the title page of your dashboard.

<h1>{{blog.title}}</h1>

avatar

The URL to your profile picture, or avatar, uploaded on the Photo page of your dashboard

<img src="{{{blog.avatar}}}" />

menu

A list of links on your site's menu, added on the Links page of your site's dashboard and pages. Each item in the list has the following properties:

{{#blog.menu}}
<a href="{{url}}">{{label}}</a>
{{/blog.menu}}

cacheID

A datestamp for when your site was last updated

timezone

Your site’s timezone in the tz database format

blogURL

URL to your site’s homepage

feedURL

Path to your site’s RSS feed

cssURL

Path to your site’s stylesheet. It contains a query string for cache-invalidation.

scriptURL

Path to your site’s JavaScript file. It contains a query string for cache-invalidation.

sitemapURL

Path to your site’s sitemap

roundAvatar

true if you’ve indicated your avatar is round, false if not

entry

id

Alias for the path property, which uniquely identifies the post.

guid

Globally unique alpha-numeric identifier for the post.

html

The full HTML of the blog post.

path

The file’s path, with the blog’s folder as root.

title

The blog post’s title.

url

The URL to the post

tags

List of tags for the entry. Each item in the list has the following properties:

{{#entry.tags}}
<a href="{{slug}}">{{tag}}</a>
{{/entry.tags}}

absoluteURL

The full-qualified URL to the post

date

The blog post’s publish date, as a human-readable string

dateStamp

The blog post’s publish date, as a unix timestamp.

A list of all the entries on your site which link to this entry. Each item in the list is an entry.

{{#backlinks}}
<a href="{{url}}">{{title}}</a>
{{/backlinks}} 

formatDate

Used to format the entry's publish date as you like, using any of the supported date tokens.

{{#formatDate}}
MMMM DDDo, YYYY 
{{/formatDate}}

formatUpdated

Used to format the entry's updated date as you like, using any of the supported date tokens.

{{#formatUpdated}}
MMMM DDDo, YYYY 
{{/formatUpdated}}

formatCreated

Used to format the entry's created date as you like, using any of the supported date tokens.

{{#formatCreated}}
MMMM DDDo, YYYY 
{{/formatCreated}}

thumbnail

object containing the thumbnails for the entry, if they exist. Blot will not increase the size of smaller images. The JSON added to each entry looks something like this

{{#thumbnail.medium}}
  <img src="{{url}}
       width="{{width}}" 
       height="{{height}}"/>
{{/thumbnail.medium}}  

metadata

object containing the metadata for the entry, if they exist.

name

The file’s name, preserving the case where possible.

size

The file’s size in bytes.

created

The file’s creation date, as a Unix timestamp.

updated

The file’s last-modified date, as a Unix timestamp.

summary

The text of the first paragraph of the entry.

titleTag

If the post’s title was generated from a heading in the blog post, this property contains that heading’s HTML. For example: <h1>Your post's <em>nice</em> title</h1>

body

The HTML of the blog post, excluding the titleTag. This property is useful if you want to manipulate the HTML of the titles of your blog posts.

teaser

The HTML of the title and the first few items in the entry. You can specify the end of the teaser by inserting the special tag {{more}} into your blog post's file. Everything before more will be included in the teaser.

teaserBody

The HTML of the first few items in the entry, excluding the title. Equivalent to teaser without the titleTag.

more

A boolean value indicating if the post’s teaser property is different to its html property. This is useful for determining whether or not to show 'read more' links.

slug

The value of the metadata property permalink. Same as URL.

The value of the metadata property permalink. Same as URL.

index

The index of the entry in the list of all of your entries. For example, the first entry published has an {{index}} of 1 and the 10th entry published has an {{index}} of 10.

menu

“true” if the entry is a page on the menu, “false” if not

page

“true” if the entry is a page, “false” if not

deleted

“true” if the entry is deleted, “false” if not

draft

“true” if the entry is a draft, “false” if not

scheduled

“true” if the entry is scheduled for future publication, “false” if not

Lists of entries

recent_entries

A list of the 30 most recent entries on your site. Each item in the list is of type entry.

{{#recent_entries}}
<a href="{{url}}">{{title}}</a>
{{/recent_entries}}

all_entries

A list of all the entries on your site. Each item in the list is of type entry.

{{#all_entries}}
<a href="{{url}}">{{title}}</a>
{{/all_entries}} 

archives

A list of all the entries on your site, structured by date. Each item in the entries property of each month is of type entry.

{{#archives}}
  <h2>{{year}}</h2>
  {{#months}}
    <h3>{{month}}</h3>
    {{#entries}}
    <a href="{{url}}">{{title}}</a>
    {{/entries}}
  {{/months}}
{{/archives}}

Lists of tags

all_tags

A list of all the tags used on your site, sorted alphabetically by tag text.

{{#all_tags}}
<a href="/tagged/{{slug}}">{{tag}}</a><br>
{{/all_tags}}

popular_tags

A list of all the tags used on your site, sorted by the number of entries with each tag.

{{#popular_tags}}
<a href="/tagged/{{slug}}">{{tag}}</a><br>
{{/popular_tags}}

Utilities

absoluteURLs

The same contents, with any relative URLs fully resolved. This is useful to create an RSS feed, since many clients struggle with relative URLs. For example

{{#absoluteURLs}}
{{{html}}}
{{/absoluteURLs

encodeJSON

The same contents, encoded appropriately for JSON. This is useful to create a JSON feed. You can use it like this

{{#encodeJSON}}
{{{html}}}
{{/encodeJSON}}

encodeURIComponent

This is useful for forming urls from entry properties

?text={{#encodeURIComponent}}
{{title}}
{{/encodeURIComponent}}

encodeXML

The same contents, encoded appropriately for XML. This is useful to create a RSS feed. You can use it like this

{{#encodeXML}}
{{{html}}}
{{/encodeXML}}                

rgb

Extracts the r, g, and b values for a passed color. Returns these values joined by a comma.

color:rgba({{#rgb}}#FF00FF{{/rgb}},0.5);

Date tokens

Token Output
Month M 1 2 … 11 12
Mo 1st 2nd … 11th 12th
MM 01 02 … 11 12
MMM Jan Feb … Nov Dec
MMMM January February … November December
Quarter Q 1 2 3 4
Qo 1st 2nd 3rd 4th
Day of Month D 1 2 … 30 31
Do 1st 2nd … 30th 31st
DD 01 02 … 30 31
Day of Year DDD 1 2 … 364 365
DDDo 1st 2nd … 364th 365th
DDDD 001 002 … 364 365
Day of Week d 0 1 … 5 6
do 0th 1st … 5th 6th
dd Su Mo … Fr Sa
ddd Sun Mon … Fri Sat
dddd Sunday Monday … Friday Saturday
Day of Week (Locale) e 0 1 … 5 6
Day of Week (ISO) E 1 2 … 6 7
Week of Year w 1 2 … 52 53
wo 1st 2nd … 52nd 53rd
ww 01 02 … 52 53
Week of Year (ISO) W 1 2 … 52 53
Wo 1st 2nd … 52nd 53rd
WW 01 02 … 52 53
Year YY 70 71 … 29 30
YYYY 1970 1971 … 2029 2030
Y 1970 1971 … 9999 +10000 +10001
Note: This complies with the ISO 8601 standard for dates past the year 9999
Week Year gg 70 71 … 29 30
gggg 1970 1971 … 2029 2030
Week Year (ISO) GG 70 71 … 29 30
GGGG 1970 1971 … 2029 2030
AM/PM A AM PM
a am pm
Hour H 0 1 … 22 23
HH 00 01 … 22 23
h 1 2 … 11 12
hh 01 02 … 11 12
k 1 2 … 23 24
kk 01 02 … 23 24
Minute m 0 1 … 58 59
mm 00 01 … 58 59
Second s 0 1 … 58 59
ss 00 01 … 58 59
Fractional Second S 0 1 … 8 9
SS 00 01 … 98 99
SSS 000 001 … 998 999
SSSSSSSSSSSSS 000[0..] 001[0..] … 998[0..] 999[0..]
Time Zone z or zz EST CSTMST PST
Z -07:00 -06:00 … +06:00 +07:00
ZZ -0700 -0600 … +0600 +0700
Unix Timestamp X 1360013296
Unix Millisecond Timestamp x 1360013296123
Question or feedback?
Contact us
On this page