[TYPO3-RTE] Attribute lang vs xml:lang - Problems with the former

Martin Kutschker masi-no at spam-typo3.org
Tue Sep 23 21:19:31 CEST 2008


Ernesto Baschny [cron IT] schrieb:
> Martin Kutschker wrote: on 23.09.2008 11:17:
> 
>> I want to enter and save SPAN tags with a lang attribute. I thought I
>> managed this once but now the RTE kills all my lang attributes. After
>> digging into the code I found the place where my attribute is removed.
>> I'm not sure why this happens and what is the purpose of it.
>>
>> The problem is in class.t3lib_parsehtml_proc.php. In the function
>> getKeepTags() is some magic that tries to clean the SPAN on the way to
>> the DB. By doing so it removes the attribute lang and title.
>>
>> I want to allow these attributes in future versions of TYPO3. Any
>> objections?
> 
> How are you able to change those attributes in current RTE? I cannot
> find any way to do that with current RTEhtmlarea buttons or context
> menus.

Easy way: custom tags (done that). More work: RTE plugin (never tried).

> And if RTE doesn't allow me to change that, it would make no
> sense to allow that information to be stored into DB (as it cannot be
> changed anymore with the UI).

I have extra CSS2 selectors that show if a text is English or German.
Works fine in FF, but needs a twist (see the DTD thread) to make it work
in IE. But of course you could also use a special class for this, but
that affects also the "UI" (see below).

But you're right the UI is clumsy. The editor has to remove any wrongly
marked text to get rid of the language attribution. Because I cannot
assure the class changes with the language I don't use the trick
mentioned above.

Masi


More information about the TYPO3-project-rte mailing list