Documentation · ViewHelper reference

XSD schema file | vhs master

Content / GetViewHelper

ViewHelper used to render get content elements in Fluid templates /

  • Tag usage example

    <v:content.get column="123" order="'sorting'" sortDirection="'ASC'" pageUid="123" contentUids="{foo: 'bar'}" sectionIndexOnly="1" loadRegister="{foo: 'bar'}" render="1" hideUntranslated="1" limit="123" slide="123" slideCollect="123" slideCollectReverse="1">
    	<!-- tag content - may be ignored! -->
    </v:content.get>
  • Inline usage example

    {v:content.get(column: 123, order: ''sorting'', sortDirection: ''ASC'', pageUid: 123, contentUids: {foo: 'bar'}, sectionIndexOnly: 1, loadRegister: {foo: 'bar'}, render: 1, hideUntranslated: 1, limit: 123, slide: 123, slideCollect: 123, slideCollectReverse: 1)}

Arguments

Argument Description Type
column

Name of the column to render

integer
contentUids

If used, replaces all conditions with an "uid IN (1,2,3)" style condition using the UID values from this array

array
hideUntranslated

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

boolean
limit

Optional limit to the total number of records to render

integer
loadRegister

List of LOAD_REGISTER variable

array
order

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.

string
pageUid

If set, selects only content from this page UID

integer
render

Return rendered result

boolean
sectionIndexOnly

If TRUE, only renders/gets content that is marked as "include in section index"

boolean
slide

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

integer
slideCollect

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.

integer
slideCollectReverse

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))

boolean
sortDirection

Optional sort direction of content elements

string
Required attribute

Revision history

commit 1fa1afa15b9494dae5dacc38c72fb2ca14d3754e
Author: Björn Fromme <*****@bjo3rn.com>
Date:   Wed Apr 3 21:41:38 2013 +0200

    [TASK] Refactor content view helpers into their own group

commit da31bad1d9bb058c072ddb5591e8ed907a1ae8e1
Author: Claus Due <*****@namelesscoder.net>
Date:   Tue Dec 31 23:08:37 2013 +0100

    [TASK] Happy new year!

commit 52bd6e41ccfef3d8193b350153912a9716e6a087
Author: Benjamin Rau <*****@codearts.at>
Date:   Tue Apr 1 21:09:00 2014 +0200

    [TASK] CGL compliance

commit da7677bc74f14e9a9300e4ba4487e52c3cb97642
Author: Claus Due <*****@namelesscoder.net>
Date:   Sun Apr 20 01:13:33 2014 +0200

    [TASK] Switch to namespaces

commit 8bb2fc5ee124ba19b0a0ab8e061c9a153fc4651f
Author: Xaver Maierhofer <*****@xwissen.info>
Date:   Sun Jan 18 17:56:13 2015 +0100

    [TASK] Reference Copyright to license.md file