[TYPO3-english] problem with rendering content from RTE field

Jigal van Hemert jigal at xs4all.nl
Mon Aug 17 07:23:59 CEST 2009


> $subMarkers['###FIELD_' . strtoupper($field) . '###'] =
> $cObj->stdWrap(htmlspecialchars($value), $this->conf['listView.'][$field
> . '_stdWrap.']);

htmlspecialchars will render the html in $value useless, so you don't want
that in this case. pi_RTEcssText() is the right funtion, but should be
used instead of htmlspecialchars:

$subMarkers['###FIELD_' . strtoupper($field) . '###'] =
$this->pi_RTEcssText($value);

If you want to apply stdWrap to it:

$subMarkers['###FIELD_' . strtoupper($field) . '###'] =
$cObj->stdWrap($this->pi_RTEcssText($value),
$this->conf['listView.'][$field
> . '_stdWrap.']);

You should decide if a particular field is an RTE field or a 'normal' field.

-- 
Jigal van Hemert.



More information about the TYPO3-english mailing list