[TYPO3-content-rendering] Target attribute XHTML/HTML

Christian Hennecke christian.hennecke at os2voice.org
Tue Oct 18 12:42:42 CEST 2011


Am 03.08.2011 10:57, schrieb Patrick Broens:

Hi Patrick,

> css_styled_content has several target parameters in constants.txt, which
> are used in setup.txt. For instance images with an external link get a
> target="_blank" by default. Of course, this is not allowed in XHTML, but
> is in HTML.

that is not correct. It is not allowed in XHTML 1.0 Strict and XHTML 1.1.

> I will make a few changes to css_styled_content setup.txt, where the
> targets are empty by default (and not rendered) unless the following
> conditions apply:
>
> * Doctype is HTML instead of XHTML
> * The target is explicitly given by a user in the RTE link wizard
>
> Why not removing the target at all in XHTML? I'm sure some companies
> will complain, because their clients still want to have the possibility
> to use the target, if they are using XHTML. For instance _blank for
> external links.
>
> Do you think this is an acceptable solution?

Why not use a JavaScript solution to attach a handler to links with a 
class like "external-link"?


More information about the TYPO3-project-content-rendering mailing list