#29782RTE marks email links as extern when there is an external link before the email link
Description
I guess the subject is self explanatory. The problem is always reproducible.
Our TYPO3 version: 4.4.10
rtehtmlarea version: 2.0.9
Example:
Switch the textmode on (do not disable the RTE) and paste the following HTML-code. You have to set the href for the internal link according to your site.
<p><a href="http://typo3.org/">EXTERNAL-TEST-URL</a></p>
<p><a href="mailto:NOT_OK@domain.com">email link NOT OK</a></p>
<p><a href="http://YOUR.DOMAIN.HERE/?id=2">INTERNAL-TEST-URL</a></p>
<p><a href="mailto:OK@domain.com">email link OK</a></p>
This will result in:
<p><a external="1" href="http://typo3.org/">EXTERNAL-TEST-URL</a></p>
<p><a external="1" href="mailto:NOT_OK@domain.com">email link NOT OK</a></p>
<p><a href="http://YOUR.DOMAIN.HERE/?id=2">INTERNAL-TEST-URL</a></p>
<p><a href="mailto:OK@domain.com">email link OK</a></p>
When you disable the RTE after inserting the above you’ll find the email links marked as external looking as follows (the mailto: should not be there!):
<link mailto:NOT_OK@domain.com>email link NOT OK</link>
Strange but true, if you add an internal link, the following email links are recognized just fine as demonstrated by the example.
As a quick work around I added the following to my RTE pageTS-Config:
RTE.default.proc{
entryHTMLparser_db = 1
entryHTMLparser_db {
tags {
a{
allowedAttribs = href,class
}
}
}
}
The RTE still adds external=“1” attributes to email links but they will be filtered before the changes are written to the database and thus “mailto:” will not be handled as the protocol for that link.
Reviews 6
- TYPO3_4-4 5540[BUGFIX] Email links marked as external when preceded by external link
- TYPO3_4-5 5539[BUGFIX] Email links marked as external when preceded by external link
- main 5514[BUGFIX] Email links marked as external when preceded by external link
- main 5537[BUGFIX] Email links marked as external when preceded by external link
- TYPO3_4-5 5515[BUGFIX] Email links marked as external when preceded by external link
- TYPO3_4-4 5516[BUGFIX] Email links marked as external when preceded by external link