Download the PHP package joinbox/email-obfuscator without Composer
On this page you can find all versions of the php package joinbox/email-obfuscator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download joinbox/email-obfuscator
More information about joinbox/email-obfuscator
Files in joinbox/email-obfuscator
Download joinbox/email-obfuscator
More information about joinbox/email-obfuscator
Files in joinbox/email-obfuscator
Vendor joinbox
Package email-obfuscator
Short Description Obfuscate emails any and everywhere
License GPL-2.0-or-later
Package email-obfuscator
Short Description Obfuscate emails any and everywhere
License GPL-2.0-or-later
Please rate this library. Is it a good library?
Informations about the package email-obfuscator
Drupal Module Email Obfuscator
The Drupal Email Obfuscator Module uses a middleware get rendered content from each request. The content is searched for emails with regexes. The emails are obfuscated depending on where the text is found.
Obfuscations
Emails in a Mailto-Link
Example: <a href="mailto:[email protected]">
- The email string excluding
mailto:
is reversed - An onfocus and an onmousedown are added which re-reverse the email after the
mailto:
. These two events cover the following cases: right-click, left-click and focus with tab. (onfocus would do it for most browsers, but Safari needs onmousedown.)
The re-reverse is only done once in order to avoid reversing back to the reversed email
All other Emails
Example: <a>[email protected]</a>
- A span with
display:none
containing a text with delimiters that are invalid email characters is added in the middle of the email
Exclusions
- Any email that is invalid (according to PHP's
filter_var
function) - Everything in the backoffice (admin pages)
- Emails inside HTML-attributes (placeholder for input fields)
- Exclude Ajax webform request:
- Because Ajax is usually used when sending a web form.
This means that the request does not contain HTML, but a JSON object in which HTML is encoded with Unicode.
The regex does not apply here and it is not necessary to obfuscate this email address as it is added by the sender.
- Because Ajax is usually used when sending a web form.
- Content in routes that are whitelisted (see below)
Whitelisting Routes
-
Define whitelisted (excluded) routes in settings.php
- IMPORTANT: If you are using CKEditor 4 you should whitelist the route
editor.link_dialog
to avoid obfuscating the email in the CKEditor link dialog.
All versions of email-obfuscator with dependencies
PHP Build Version
Package Version
No informations.
The package joinbox/email-obfuscator contains the following files
Loading the files please wait ....