简体   繁体   中英

TYPO3 EXT:Content Element Wrap and EXT:GridElements

I need a way to add classes to specific Content Elements in order to style them with css and animate with js/Jquery.

I found the EXT:Content Element Wrap, which totaly works on its own, but combined with EXT: GridElements it does not work. (By not work i mean: some css styling is lost and most of the images cannot be loaded)

Is there any way to use EXT:Content Element Wrap together with EXT: GridElements? Or is there any other way to add class to my Content Elements?

thanks in andvance. Mathias :)

In your site package extension you could add custom template files for the content elements and add your css class in there.

In the file Configuration/TypoScript/setup.typoscript file you add:

lib.contentElement.templateRootPaths.100 = EXT:your_site_package_extension/Resources/Private/Content/Templates/
lib.contentElement.layoutRootPaths.100 = EXT:your_site_package_extension/Resources/Private/Content/Layouts/
lib.contentElement.partialRootPaths.100 = EXT:your_site_package_extension/Resources/Private/Content/Partials/

Now you have to have a look at the original TYPO3 files of the system extension fluid_styled_content which is located here:

typo3_src/typo3/sysext/fluid_styled_content

If you want to add your css class in every content element you should fe add it in the appropriate layout file.

Copy the file you want to change into the appropriate folder of your sitepackage extension and adapt it to your needs.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM