[TYPO3-RTE] make custom tag work in rtehtmlarea

Stanislas Rolland stanislas.rolland at fructifor.ca
Sat Apr 15 05:27:24 CEST 2006


R. van Twisk a écrit :
> I got a little further down the road:
> 
> This works now..
> <rvt>Some Text</rvt>
> 
> 
> however my attributes always get's lost:
> <rvt someAttrib>Some Text</rvt>
> <rvt someAttrib="value">Some Text</rvt>
> 
> 
> In the above cases when I switch from source to HTML in rtehtmlarea,
> My attribs are gone.
> 

The default processing configuration of rtehtmlarea uses the following 
setting:
RTE.default.proc.entryHTMLparser_db.keepNonMatchedTags = protect

This means that a tag that is not in the list of allowed tags will be 
transformed into html entities. However, if you use the default 
processing configuration, it should be transformed to normal characters 
on the way to the database. This should allow the user to edit the tag 
in html or wysiwyg mode. Yet, you should be able to configure frontend 
rendering of the tag in whatever way you wish.

I would recommend not to include your custom tag in the list of tags 
allowed in the RTE. In other words, not to edit the tags in text mode. 
IE and Mozilla/Firefox will handle such tags in inconsistent ways, and 
may not recognize any content between the opening and closing tags as 
belonging to your element.

Regards,
Stanislas



More information about the TYPO3-project-rte mailing list