TYPO3 flux: Access page settings in content element

revision c190de264fb680d5474383f7c99b00a629a53a77

raw

README.rst

I want to access settings from the page configuration when a content element is rendered.

Search keywords: - fluidpages settings in fluidcontent - typo3 flux content element read flux page settings - typo3 parse tx_fed_page_flexform

Solution

Manually parse the flexform data. "page" contains the page record.

Nested form:

<flux:form.data table="pages" field="tx_fed_page_flexform" record="{page}" as="pagesettings">
  <f:debug>{pagesettings.settings.accentcolor}</f:debug>
</flux:form.data>

With an variable:

<v:variable.set name="pagesettings" value="{flux:form.data(table:'pages', field:'tx_fed_page_flexform', record: page)}"/>
<f:debug>{pagesettings.settings.accentcolor}</f:debug>

History