---
title: "Feature: #92749 - Improve content object initialization in HtmlViewHelper"
manual: "TYPO3 Core Changelog"
version: "main"
permalink: "https://docs.typo3.org/permalink/changelog:feature-92749"
source: "Changelog/12.0/Feature-92749-ImproveContentObjectInitializationInHtmlViewHelper.rst"
typo3-version: "12.0"
typo3-major: 12
type: "feature"
issue: 92749
forge: "https://forge.typo3.org/issues/92749"
tags: ["Frontend", "TypoScript", "ext:fluid"]
rendered: "2026-09-20T18:31:11+00:00"
---

# Feature: #92749 - Improve content object initialization in HtmlViewHelper {#feature-92749}

See [forge#92749](https://forge.typo3.org/issues/92749)

## Description {#description}

New options are available for the `f:format.html` ViewHelper,
related to the initialization of the underlying content object. The options
are similar to the ones, available for the `f:cObject` ViewHelper.

With the `data` argument an integrator can pass an array or an object (e.g. a
domain model), which will be used as data record on initialization.

With the `currentValueKey` argument, one can specify the array key of the
provided data record, which should be used as the current value.

Alternatively, one can use the new `current` argument to set a static value
as current value for the content object.

Additionally, with the `table` argument, the `ContentObjectRenderer`
receives the table name, the given data record is from.

## Example {#example}

Access a news record title with `CURRENT:1` and resolve a marker:

```html
<f:format.html
        parseFuncTSPath="lib.news"
        data="{uid: 1, title: \'Great news\'}"
        currentValueKey="title">
    ###PROJECT### news:
</f:format.html>
```

```typoscript
constants.PROJECT = TYPO3
lib.news {
    htmlSanitize = 1
    constants = 1
    plainTextStdWrap.noTrimWrap = || |
    plainTextStdWrap.dataWrap = |{CURRENT:1}
}
```

This will result in:

```html
TYPO3 news: Great news
```

## Impact {#impact}

The `f:format.html` ViewHelper can now be utilized in more customized use cases.
