Typo3: htmlRTE “Zebra” tables (classes for odd/even rows) using TSConfig
It took me some hours and the documentation is not very good, but finally I have found out how to mark up table rows from RTE tables (not elements with content type “table”) with alternating CSS classes. Put this into your page TSConfig:
RTE.classes.zebra-rows {
name = Zebra table
alternating.rows {
startAt = 1
oddClass = odd
evenClass = even
}
}
RTE.default {
ignoreMainStyleOverride = 0
inlineStyle.zebra-tables (
table.zebra-rows { }
table.zebra-rows tr { background: lime; } /* or whatever color */
table.zebra-rows tr.odd { background: red; } /* or whatever color */
)
classesTable = zebra-rows
classesTR = odd, even
proc.allowedClasses … Continue Reading