[TYPO3] Rendering special way content elements
Tapio Markula
tapio.markula at xetpoint.fi
Mon May 26 18:27:07 CEST 2008
Hi
I got this kind of code
styles.content.getBorder >
styles.content.getBorder = COA
styles.content.getBorder {
# Render all content elements, except the last one - was
previous bottomBRLast for the last item
10 = CONTENT
10 {
table = tt_content
select.orderBy = sorting
select.where = colPos=3
select.languageField = sys_language_uid
select.max = total-1
renderObj < tt_content
renderObj.stdWrap.wrap = |<img
src="/fileadmin/template/main/kuvat/viiva268.gif" width="268px"
height="4px" />
}
# Render the last content element.
20 < .10
20.select.max >
20.select.begin = total-1
20.renderObj.stdWrap.wrap = |<img
src="/fileadmin/template/main/kuvat/viiva268.gif" width="268px"
height="4px" />
}
That works *olmost* but if there is just one content element, it renders
it *twice*
maybe need to count somewhat elements and if just one, don't render
section '20' - how to do that
More information about the TYPO3-english
mailing list