0

In TYPO3 8.7 I am trying to override the file Textpic.html from fluid_styled_content so that I can use my own rendering for the textpic content element.

As long as I modify the original file inside the extension itself, this is working fine.

However, I want to create my own copy of this file and use that copy. This is not working - TYPO3 does not use my own version of the file.

Here is what I did:

In the Setup field of my TypoScript template I added:

lib.contentElement.templateRootPaths.100 = /fileadmin/template/Templates/

Then I copied Textpic.html from fluid_styled_content/Resources/Private/Templates into my folder /fileadmin/template/Templates so that it becomes /fileadmin/template/Templates/Textpic.html.

Any hints, what I might be missing?

Peter Kraume
  • 3,577
  • 2
  • 21
  • 39
Christopher
  • 778
  • 6
  • 10

1 Answers1

1

You can do this by setting constants. For example

styles.templates {
    templateRootPath = EXT:siteconfig/Resources/Private/Extensions/fluid_styled_content/Templates/

    partialRootPath = EXT:siteconfig/Resources/Private/Extensions/fluid_styled_content/Partials/

    layoutRootPath = EXT:siteconfig/Resources/Private/Extensions/fluid_styled_content/Layouts/
}

So these locations will be checked first, if no file is there for a certain contentelement, the version of fluid_styled_content will be used.

Check the original at /typo3/sysext/fluid_styled_content/Configuration/TypoScript/constants.txt

Make sure you keep the same subfolder structure for partials.

  • I tried this way now as well, but no success. I have double and tripple checked the file paths and I do not see a mistake in there. Actually, I am doing exactly the same for a partial and it is working... – Christopher Aug 17 '18 at 12:22
  • It should work. Did you clear cache? Are you not mixing up Textmedia with Textpic? Did you make the template changes within ? – Jacco van der Post Aug 17 '18 at 12:57