content.render ViewHelper <vhs:content.render>
ViewHelper used to render content elements in Fluid templates.
Render a single content element by its UID
Let's assume that the variable settings.
contains the uid
of a content element.
It can be rendered as follows:
<v:content.render contentUids="{0: settings.element.uid}"/>
Copied!
Arguments
column
- DataType
- integer
- Required
- false
- Description
- Column position number (colPos) of the column to render
order
- DataType
- string
- Default
- 'sorting'
- Required
- false
- Description
- Optional sort field of content elements - RAND() supported. Note that when sliding is enabled, the sorting will be applied to records on a per-page basis and not to the total set of collected records.
sortDirection
- DataType
- string
- Default
- 'ASC'
- Required
- false
- Description
- Optional sort direction of content elements
pageUid
- DataType
- integer
- Required
- false
- Description
- If set, selects only content from this page UID. Ignored when "contentUids" is specified.
contentUids
- DataType
- mixed
- Required
- false
- Description
- If used, replaces all conditions with an "uid IN (1,2,3)" style condition using the UID values from this array
sectionIndexOnly
- DataType
- boolean
- Required
- false
- Description
- If TRUE, only renders/gets content that is marked as "include in section index"
loadRegister
- DataType
- mixed
- Required
- false
- Description
- List of LOAD_REGISTER variable
render
- DataType
- boolean
- Default
- true
- Required
- false
- Description
- Render result
hideUntranslated
- DataType
- boolean
- Required
- false
- Description
- If FALSE, will NOT include elements which have NOT been translated, if current language is NOT the default language. Default is to show untranslated elements but never display the original if there is a translated version
limit
- DataType
- integer
- Required
- false
- Description
- Optional limit to the total number of records to render
slide
- DataType
- integer
- Required
- false
- Description
- Enables Record Sliding - amount of levels which shall get walked up the rootline, including the current page. For infinite sliding (till the rootpage) set to -1. Only the first PID which has at minimum one record is used.
slideCollect
- DataType
- integer
- Required
- false
- Description
- If TRUE, content is collected up the root line. If FALSE, only the first PID which has content is used. If greater than zero, this value overrides $slide.
slideCollectReverse
- DataType
- boolean
- Required
- false
- Description
- Normally when collecting records the elements from the actual page get shown on the top and those from the parent pages below those. You can invert this behaviour (actual page elements at bottom) by setting this flag.
as
- DataType
- string
- Required
- false
- Description
- Template variable name to assign; if not specified the ViewHelper returns the variable instead.