---
title: "page-content data processor"
manual: "TypoScript Explained"
version: "14.3"
permalink: "https://docs.typo3.org/permalink/t3tsref:pagecontentfetchingprocessor@14.3"
source: "DataProcessing/PageContentFetchingProcessor.rst"
rendered: "2026-10-01T16:17:37+00:00"
---

# `page-content` data processor {#pagecontentfetchingprocessor}

This data processor `\TYPO3\CMS\Frontend\DataProcessing\PageContentFetchingProcessor`,
alias `page-content`, loads all `tt_content` records from the current
[backend layout](https://docs.typo3.org/m/typo3/reference-coreapi/14.3/en-us/ApiOverview/Backend/BackendLayout.html#be-layout) into
the template with a given identifier for each `colPos`, also respecting slideMode or
collect options based on the page layouts content columns.

An array of [Record objects](https://docs.typo3.org/m/typo3/reference-coreapi/14.3/en-us/ApiOverview/Database/DatabaseRecords/RecordObjects.html#record-objects) will be passed to
the Fluid template. You can use the
[f:cObject ViewHelper](https://docs.typo3.org/other/typo3/view-helper-reference/14.3/en-us/Global/CObject.html#typo3-fluid-cobject) to
display the content elements.

**Table of contents**

-   [Options](https://docs.typo3.org/permalink/t3tsref:options@14.3)
-   [Example: Use the page-content data processor to display the content](https://docs.typo3.org/permalink/t3tsref:example-use-the-page-content-data-processor-to-display-the-content@14.3)
-   [Modify the result via AfterContentHasBeenFetchedEvent](https://docs.typo3.org/permalink/t3tsref:modify-the-result-via-aftercontenthasbeenfetchedevent@14.3)

## Options {#pagecontentfetchingprocessor-options}

**as**

-   **as**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@14.3)
    -   *Default:* "content"

    Name for the variable in the Fluid template.

**if**

-   **if**

    -   *Type:* [if](https://docs.typo3.org/permalink/t3tsref:if@14.3) condition
    -   *Default:* ''

    Only if the condition is met the data processor is executed.

## Example: Use the page-content data processor to display the content {#pagecontentfetchingprocessor-example}

**config/sites/my-site/setup.typoscript**

```typoscript
page = PAGE
page {
  10 = PAGEVIEW
  10 {
    paths.10 = EXT:my_sitepackage/Resources/Private/Templates/
    dataProcessing.10 = page-content
    dataProcessing.10.as = myContent
  }
}

```

Use the identifiers of the columns in the Fluid template:

**EXT:my_sitepackage/Resources/Private/Templates/Pages/Default.fluid.html**

```html
<main>
  <f:for each="{myContent.jumbotron.records}" as="contentElement">
    <f:if condition="{contentElement.fullType} = 'tt_content.my_extension_jumbotron'">
      <h2>{contentElement.header}</h2>
      <f:format.html>{contentElement.bodytext}</f:format.html>
    </f:if>
  </f:for>
  <f:for each="{myContent.left.records}" as="contentElement">
    <f:cObject
      typoscriptObjectPath="{contentElement.mainType}"
      table="{contentElement.mainType}"
      data="{contentElement}"
    />
  </f:for>
</main>
<aside>
  <f:for each="{myContent.right.records}" as="contentElement">
    <f:if condition="{contentElement.fullType} = 'tt_content.header'">
      <h2>{contentElement.header}</h2>
    </f:if>
  </f:for>
</aside>

```

You can use the [f:cObject ViewHelper](https://docs.typo3.org/other/typo3/view-helper-reference/14.3/en-us/Global/CObject.html#typo3-fluid-cobject)
to render the content element using [`typo3/cms-fluid-styled-content`](https://packagist.org/packages/typo3/cms-fluid-styled-content)
or render it your self.

-   **`{contentElement.mainType}`**

    Is always "tt_content" for content elements.

-   **`{contentElement.fullType}`**

    Is composed of "tt_content.\[CType\]". For a content element of type text it
    contains "tt_content.text".

The [backend layout](https://docs.typo3.org/m/typo3/reference-coreapi/14.3/en-us/ApiOverview/Backend/BackendLayout.html#be-layout) is defined like this:

**config/sites/my-site/page.tsconfig**

```typoscript
mod.web_layout.BackendLayouts {
  default {
    title = Default
    config {
      backend_layout {
        colCount = 2
        rowCount = 2
        rows {
          1 {
            columns {
              1 {
                name = Jumbotron
                colPos = 1
                identifier = jumbotron
                slideMode = slide
                colspan = 2
                allowedContentTypes = tx_myextension_stage, header
              }
            }
          }

          2 {
            columns {
              1 {
                name = Left
                colPos = 0
                identifier = left
              }

              2 {
                name = Right
                colPos = 2
                identifier = right
                slideMode = collectReverse
                disallowedContentTypes = tx_myextension_stage, textmedia
              }
            }
          }
        }
      }
    }
  }
}

```

## Modify the result via AfterContentHasBeenFetchedEvent {#pagecontentfetchingprocessor-aftercontenthasbeenfetchedevent}

<!-- TODO: no Markdown rendering for "versionadded" -->

The event AfterContentHasBeenFetchedEvent
has been introduced to adjust the page content fetched by the page-content
data processor.

The event [AfterContentHasBeenFetchedEvent](https://docs.typo3.org/permalink/t3coreapi:aftercontenthasbeenfetchedevent)
can be used to modify the content elements fetched by the `page-content`
data processor.

See the following example:
[Filter content elements provided by the page-content data processor](https://docs.typo3.org/m/typo3/reference-coreapi/14.3/en-us/ApiOverview/Events/Events/Frontend/AfterContentHasBeenFetchedEvent.html#AfterContentHasBeenFetchedEvent-example).
