[TYPO3-english] Wrap every two items in tt_news

Ralf-Rene Schröder ralf.rene at online.de
Wed May 14 19:24:09 CEST 2014


Am 14.05.2014 17:14, schrieb Sergio Catalá:
> Hi list,
> 
> I am using tt_news (3.5.2) and I would like to wrap, in a news list
> (code: LIST), every two single items with a specific div (<div
> class="row"></div>). I mean:
> 
> <div class="row">
>     <div class="item1">...</div>
>     <div class="item2">...</div>
> </div>
> <div class="row">
>     <div class="item3">...</div>
>     <div class="item4">...</div>
> </div>


> The problem is that for an odd number of news items in the list, the
> surrounding div would be opened.
> 
> Any solution for that problem? Any hint?

try it this way...

<!-- ###CONTENT### begin-->
    <!-- ###NEWS### begin -->
    <div class"row">
        <div class="events_content round_corn">
            ###NEWS_IMAGE###
            <p class="date">###NEWS_DATE###, ###NEWS_SUBHEADER###</p>
            <p
class="title"><!--###LINK_ITEM###-->###NEWS_TITLE###<!--###LINK_ITEM###--></p>

    <!-- ###NEWS### end-->
    <!-- ###NEWS_1### begin -->
	</div>
        <div class="events_content round_corn">
            ###NEWS_IMAGE###
            <p class="date">###NEWS_DATE###, ###NEWS_SUBHEADER###</p>
            <p
class="title"><!--###LINK_ITEM###-->###NEWS_TITLE###<!--###LINK_ITEM###--></p>

    <!-- ###NEWS_1### end-->
    </div>
</div>
<!-- ###CONTENT###  end -->



-- 
image[FORMAT] - Ralf-René Schröder
http://www.image-format.eu ... Wir geben Ihrem Image das richtige Format


More information about the TYPO3-english mailing list