---
title: "Constants"
manual: "Klaro! Consent Manager"
version: "main"
permalink: "https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:configuration-typoscript-constants@main"
source: "Configuration/TypoScriptReference/Constants.rst"
rendered: "2026-09-24T10:59:30+00:00"
---

# Constants {#configuration-typoscript-constants}

These values are defined in
`Configuration/Sets/KlaroConsentManager/settings.definitions.yaml` and
`Configuration/TypoScript/constants.typoscript`.

With the recommended [Site Set integration](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:configuration-site-set@main),
override them as Site Settings in
`config/sites/<site-identifier>/settings.yaml` by using flat map keys:

```yaml
plugin.tx_klaroconsentmanager.view.templateRootPath: 'EXT:sitepackage/Resources/Private/Templates/'
```

With the [Static TypoScript Include fallback](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:configuration-typoscript@main),
override the same values as classic TypoScript constants.

## View {#configuration-typoscript-constants-view}

The following options are located under the following path:
`plugin.tx_klaroconsentmanager.view`

### Template root path {#configuration-typoscript-constants-view-templaterootpath}

-   **templateRootPath**

    -   *type:* string
    -   *Default:* empty
    -   *Path:* plugin.tx_klaroconsentmanager.view

    Defaults to `EXT:klaro_consent_manager/Resources/Private/Templates/`.
    Override this path to replace individual frontend Fluid templates. See
    [Reference to your own Fluid files](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:howto-reference-fluid@main) for the backend-field alternative and expected
    directory structure.

### Partial root path {#configuration-typoscript-constants-view-partialrootpath}

-   **partialRootPath**

    -   *type:* string
    -   *Default:* empty
    -   *Path:* plugin.tx_klaroconsentmanager.view

    Defaults to `EXT:klaro_consent_manager/Resources/Private/Partials/`.
    Override this path to replace individual frontend Fluid partials.

### Layout root path {#configuration-typoscript-constants-view-layoutrootpath}

-   **layoutRootPath**

    -   *type:* string
    -   *Default:* empty
    -   *Path:* plugin.tx_klaroconsentmanager.view

    Defaults to `EXT:klaro_consent_manager/Resources/Private/Layouts/`.
    Override this path to replace frontend Fluid layouts.

## Settings {#configuration-typoscript-constants-settings}

The following options are located under the following path:
`plugin.tx_klaroconsentmanager.settings`

### Klaro CSS {#klaro-css}

-   **css.klaro-default**

    -   *type:* string
    -   *Default:* EXT:klaro_consent_manager/Resources/Public/Css/klaro.min.css
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    CSS file registered for the Klaro frontend.

### Custom additions for Klaro CSS {#custom-additions-for-klaro-css}

-   **css.klaro-custom**

    -   *type:* string
    -   *Default:* EXT:klaro_consent_manager/Resources/Public/Css/klaro-custom.min.css
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    Additional extension CSS with TYPO3-specific Klaro adjustments.

### Klaro JavaScript {#klaro-javascript}

-   **javascript.klaro-default**

    -   *type:* string
    -   *Default:* EXT:klaro_consent_manager/Resources/Public/JavaScript/klaro-no-translations-no-css.js
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    Self-hosted Klaro JavaScript file registered in the frontend.

### Replace attributes {#replace-attributes}

-   **contextualconsent.replaceAttributes**

    -   *type:* string (comma-separated list)
    -   *Default:* src,href
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    Comma-separated list of attributes that are moved to matching
    `data-*` attributes in [contextual consent](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:features-contextual-consent@main) content. The default moves `src` and `href`
    to `data-src` and `data-href`.

### Main section only {#main-section-only}

-   **contextualconsent.mainSectionOnly**

    -   *type:* boolean
    -   *Default:* true
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    Activate this option if the [contextual consent](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:features-contextual-consent@main) placeholder should be limited to the main
    content of the content element, without heading and footer.

### Disable Klaro Consent Management {#disable-klaro-consent-management}

-   **configuration.disabled**

    -   *type:* boolean
    -   *Default:* false
    -   *Path:* plugin.tx_klaroconsentmanager.settings

    Disable the frontend Klaro integration while keeping the extension
    installed and configured. This value is one of the prerequisites evaluated
    by [TypoScript condition to check if Klaro is used](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:klaroisactive@main).
