WordPress.org

Ready to get started?Download WordPress

Forums

Email Address Encoder
[resolved] Feature request: also encode "@"-substitutes (9 posts)

  1. owcv
    Member
    Posted 2 years ago #

    Is it possible that you also implement the encoding of mail adresses written with [at] instead of @ too?

    For example, if I have an email adress on my wordpress blog like:
    name[at]domain.com

    That this one is also encoded by your plugin.

    Can you do that? :-)

    http://wordpress.org/extend/plugins/email-address-encoder/

  2. Till Krüss
    Member
    Plugin Author

    Posted 2 years ago #

    Hey!

    I'll release a new version of the plugin in the next days which will allow you to easily manipulate the regular expression, so you can parse your special @ too.

    Cheers,
    Till

  3. Till Krüss
    Member
    Plugin Author

    Posted 2 years ago #

    With version 1.0.2 you can do a fancy override of the regular expression like that: <?php add_filter('eae_regexp', function($pattern) { return str_replace('\@', '(\@|\[at\])', $pattern); }); ?>

  4. owcv
    Member
    Posted 2 years ago #

    and where to place that?

  5. owcv
    Member
    Posted 2 years ago #

    ...and besides, I don't want to parse my "@", I write the mail-adresses in my posts and pages with "[at]". So it would be great if mail-adresses written that way, will be encoded too! ;-)

  6. owcv
    Member
    Posted 2 years ago #

    If I change line 62 in email-address-encoder.php (ver 1.0.1) from

    \@

    to

    \@|\[at\]

    that does exactly the job!

    So I would appreciate, if you could include that in one of your next updates.

  7. Till Krüss
    Member
    Plugin Author

    Posted 2 years ago #

    Hey!

    I won't include your desired changed in the plugin, it's too much of a corner case. However I version 1.0.2 introduced the eae_regexp filter, as written earlier, which allows you to override the regular expression pattern yourself.

    Just place the code written code in your Theme's functions.php or in a Must Use Plugin.

    Cheers!

  8. epistates
    Member
    Posted 2 years ago #

    how about just implement a setting, where you can choose to change the @ into [at] or even better the plugin converses all @ automatically into [at]. that would also raise the security. a mix of antispam-technology is better than just one method.

  9. Till Krüss
    Member
    Plugin Author

    Posted 2 years ago #

    I intent to keep this plugin simple for overall compatibility. If you want to convert @ into [at] you can use the eae_method filter, but this will break mailto-links.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic