Difference between revisions of "Liquid Template Variables - article"
From Spiffy Stores Knowledge Base
Line 27: | Line 27: | ||
== <code>article.more_tag?</code> == | == <code>article.more_tag?</code> == | ||
− | Returns true if the <code>'<!--more-->'</code> tag is present in the article. | + | Returns true if the <code><nowiki>'<!--more-->'</nowiki></code> tag is present in the article. |
== <code>article.created_at</code> == | == <code>article.created_at</code> == |
Revision as of 12:28, 23 March 2011
The liquid template variable article has the following attributes:
Contents
article.id
Returns the unique internal number of the article.
This is normally only for internal usage.
article.title
Returns the title of this article.
article.author
Returns the name of the author of this article.
article.content
Returns the content of this page.
article.synopsis
Returns the content of this page, up to a tag, if it exists.
This is useful for providing a summary of blog articles, without including the full text of the article.
article.more_tag?
Returns true if the '<!--more-->'
tag is present in the article.
article.created_at
Returns the creation date and time of the article.
{{ article.created_at | date: "%Y %h" }}
article.url
The is the relative URL address of the article.
article.blog
This is the blog that this article belongs to.
article.type
Returns the type of the object, in this case, 'article'.