[TYPO3-dev] Wrap div around own plugin
Martin Koppelaar
hagipro at gmail.com
Thu Nov 14 10:25:46 CET 2013
Hi group,
I have created a plugin that produces a slider. As this slider is used in more templates for this template I am working on I want to wrap the slider from my template and not in the plugin itself.
This code works:
tt_content.stdWrap.innerWrap.cObject = TEXT
tt_content.stdWrap.innerWrap.cObject {
value = |
if.equals.field = list_type
if.value = my_plugin
wrap (
<div class="slider-wrapper">
<div class="slider">|</div>
<div class="menu-front"></div>
<div class="menu-button-back"></div>
</div>
)
}
However, it breaks the div that CssStyledContent wraps around the object, it is removed.
This is removed:
<div id="c1309" class="hide-for-small" >
</div>
And it is not only removed from the slider plugin, it is removed from all other elements.
As I am only beginning to learn TypoScript can someone please explain what I should do to achieve this:
<div id="c1309" class="hide-for-small">
<div class="slider-wrapper">
[etc]
</div>
</div>
For your information, the "hide-for-small" class is a indentation / frame change I created like this:
tt_content.stdWrap.innerWrap.cObject {
150 < tt_content.stdWrap.innerWrap.cObject.default
150.15.value = hide-for-small
160 < tt_content.stdWrap.innerWrap.cObject.default
160.15.value = show-for-small
}
This class is used in the ZURB Foundation Framework for mobile use.
Kind regards,
Martin
More information about the TYPO3-dev
mailing list