Attention
TYPO3 v11 has reached end-of-life as of October 31th 2024 and is no longer being maintained. Use the version switcher on the top left of this page to select documentation for a supported version of TYPO3.
Need more time before upgrading? You can purchase Extended Long Term Support (ELTS) for TYPO3 v11 here: TYPO3 ELTS.
Uri.email ViewHelper <f:uri.email>
Deprecated since version TYPO3 v11.5
In favor of allowing more content security policy scenarios, URI
is not used anymore per default. As a result, <f:
ViewHelper became obsolete. The ViewHelper will be removed with TYPO3 v12.0.
See Migration for details.
Email URI ViewHelper. Generates an email URI incorporating TYPO3s spamProtectEmailAddresses TypoScript setting.
Migration
In case config.
is used, make use of
<f.
ViewHelper which returns the
complete <a>
tag like this:
<a href="#" data-mailto-token="ocknvq,hqqBdct0vnf"
data-mailto-vector="1">user(at)my.example(dot)com</a>
In case spam-protected is not used or not useful (for example in backend user interface), view-helper invocation can be omitted completely.
Example
Basic email URI:
<f:uri.email email="foo@bar.tld" />
Output:
javascript:linkTo_UnCryptMailto('ocknvq,hqqBdct0vnf');
Depending on spamProtectEmailAddresses setting.
Source code
Go to the source code of this ViewHelper: EmailViewHelper.php (GitHub).
Arguments
The following arguments are available for <f:
:
-
- Type
- string
- Required
true
The email address to be turned into a URI