[TYPO3-core] RFC: Bug 5602: spamProtectEmailAddresses_atSubst is not recognized correctly
Martin Kutschker
martin.kutschker-n0spam at no5pam-blackbox.net
Sun Nov 25 12:14:35 CET 2007
Oliver Hader schrieb:
> Hi Masi,
>
> Martin Kutschker schrieb:
>> Oliver Hader schrieb:
>>> This is a SVN patch request.
>>>
>>> Problem:
>>> Imagine a TypoScript like the following one and test it:
>>> config {
>>> spamProtectEmailAddresses = 2
>>> spamProtectEmailAddresses_atSubst = [at]
>>> spamProtectEmailAddresses_lastDotSubst = [dot]
>>> }
>>> 10 = TEXT
>>> 10.value = <b>john at doe.com</b>
>>> 10.typolink.parameter = john at doe.com
>>> The result is, the the e-mail address is not "protected" by [at] or
>>> [dot] and is shown unsubstituted. Not remove the wrapping bold tags
>>> (<b>|</b>) from the value property of the TEXT object from above and
>>> test again. Everything fine, as expected...
>>> tslib_cObj:getMailTo($mailAddress,$linktxt,$initP='?') only substituded
>>> the "at" and "dot" if the $mailAddress (here: 10.typolink.parameter) and
>>> the $linktxt (here: 10.value) are the same. This behavior was introduced
>>> in RFC #3985 by... me (sorry!)...
>>>
>>> Solution:
>>> Create a spam protected variant of the $mailAddress and and the end of
>>> tslib_cObj:getMailTo() substitute the unprotected mail address by the
>>> spam protected mail address. In this case it doesn't matter in which
>>> context/wraps the e-mail address is nested.
>>>
>>> Comments:
>>> #RFC 3985 was about wrong substitution of "dot" and "at" in non e-mail
>>> addresses, like filenames or directories. See the following example:
>>> <a href="mailto:..."><img src="/my.files/logo.jpg" /></a>
>>> was changed to
>>> <a href="mailto:..."><img src="/my.files/logo[dot]jpg" /></a>
>> Any news on this? The discussion did not end...
>
> Well, concerning Franz' post, I don't think this is a misbehaviour. On
> using "spamProtectEmailAddresses = ascii", we'll get the following for
> the e-mail address "john at doe.com":
>
> <a
> href="mailto:john@doe.com">john[at]doe.com</a>
>
> The 'mailto:' is also converted to ASCII characters. But this doesn't
> matter, since browsers accept this, too.
And any mail harvester too. This is the most pointless option in TYOP3
ever ;-)
Masi
PS: And now for some nit picking. They are not ASCII characters, they
are (SGML) entities. And this entities are not ASCII encoded they are in
Unicode.
More information about the TYPO3-team-core
mailing list