Project

General

Profile

Feature #17792 ยป rtehtmlarea_feature_6715.patch

Administrator Admin, 2007-11-15 05:01

View differences:

t3lib/class.t3lib_parsehtml_proc.php (working copy)
// GOING from database to Rich Text Editor:
case 'rte':
// Transform bold/italics tags to strong/em
if (isset($keepTags['b'])) {$keepTags['b']=array('remap'=>'STRONG');}
if (isset($keepTags['i'])) {$keepTags['i']=array('remap'=>'EM');}
if (!$this->procOptions['doNotTransformBoldAndItalicTags']) {
// Transform bold/italics tags to strong/em
if (isset($keepTags['b'])) {$keepTags['b']=array('remap'=>'STRONG');}
if (isset($keepTags['i'])) {$keepTags['i']=array('remap'=>'EM');}
}
// Transforming keepTags array so it can be understood by the HTMLcleaner function. This basically converts the format of the array from TypoScript (having .'s) to plain multi-dimensional array.
list($keepTags) = $this->HTMLparserConfig($this->procOptions['HTMLparser_rte.'],$keepTags);
......
// GOING from RTE to database:
case 'db':
// Transform strong/em back to bold/italics:
if (isset($keepTags['strong'])) { $keepTags['strong']=array('remap'=>'b'); }
if (isset($keepTags['em'])) { $keepTags['em']=array('remap'=>'i'); }
if (!$this->procOptions['doNotTransformBoldAndItalicTags']) {
// Transform strong/em back to bold/italics:
if (isset($keepTags['strong'])) { $keepTags['strong']=array('remap'=>'b'); }
if (isset($keepTags['em'])) { $keepTags['em']=array('remap'=>'i'); }
}
// Setting up span tags if they are allowed:
if (isset($keepTags['span'])) {
    (1-1/1)