[TYPO3-english] removeWrapping depending on colPos

Muriel le Pair typo3 at strangefruit.nl
Thu Dec 9 12:19:07 CET 2010


Hi,

I'm struggling with the automatic wraps generated by TYPO3.

I would like to alter the wrapping of text depending of the column the 
content is placed in.

For instance:
colPos = 0 => remove all tags
colPos = 1 => standard wrap

This works fine for the outerwrap:

# remove standard datawrap of all text elements
tt_content.text.20.dataWrap = |

# add div to normal col, leave others blank
tt_content.text.20.stdWrap.outerWrap = <div class="toggle">|</div>
tt_content.text.20.stdWrap.outerWrap.if {
     equals.field = colPos
     value = 0
}

But the standard <p> wrap that TYPO3 produces for dubious reasons is not 
removed.
So I tried to do the following:

#remove wrapping for colPos 0
tt_content.text.20.parseFunc.nonTypoTagStdWrap.encapsLines {
    removeWrapping = 1
    removeWrapping.if {
       equals.field = colPos
       value = 0
   }
}

But this doesn't work. It removes all tags independent of the colPos. So 
in other words the if statement is ignored.

Does anybody know why? And why does the if statement only works in 
certain cases?

--
kind regards,

Muriel le Pair


More information about the TYPO3-english mailing list