Learn

get_content

Retrieves the page variables for a given content path.

{{ get_content }}

Returns content for a given content path.

Sample Usage

{{ get_content from="about/team" }}
    {{ title }}
{{ /get_content }}

Parameters

from

The URL to retreive data from.

{{ get_content from="survival-guide/makeshift-axes" }}

Required

show_hidden

Boolean setting to show hidden files or not

Default: false

{{ get_content show_hidden="false" }}

show_past

Boolean setting to enable date-based entries that have dates in the past.

Default: true

{{ get_content show_past="true" }}

show_future

Boolean setting to enable date-based entries that have dates in the future.

Default: false

{{ get_content show_future="true" }}

conditions

Conditions let you filter on and and every custom field in your entry data with the use a comma-separated string of key:value pairs.

{{ get_content conditions="author:jack" }}
{{ get_content conditions="type:beef|pork|bacon" }}

You can also string together multiple conditions by separating them with commas:

conditions="author:jack,featured:yes"

You can even perform “not” conditions by adding a ! mark:

conditions="author:!jack"

This article was last updated on September 13th, 2016. Find an error? Please let us know!