We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 13428 ☆ A M B ☆
    • 1,031 Posts
    This is an auto-generated topic for emo - E-Mail Obfuscation 1.4-rc2 by Jako.

    Brief Description:

    This plugin replaces all plaintext emails and email links with span elements. Then email addresses are encrypted and stored in javascript variables. Javascript decryption routines are triggered by the browser on window.onload event and replace the span elements with the real email addresses.
    New features in 1.4:

    • Does not modify addresses inside form tags, works better with mailto hrefs
    • Call javascript file by regClientStartupScript
    • Noscript message could be set to an ID and a link to this page will be generated (i.e. to link to a contact page with disabled javascript)
      • 1892
      • 82 Posts
      Thanks for that - I’ve been using emo for a couple of sites and a recent one needed a login form. Just before Christmas I noticed the problem with the forms but struggled about fixing it. This week I was determined to sort it and lo and behold this update pops up - so many thanks.

      I don’t know enough to work out whether it’s my site or the plugin but I had to tweak a couple of things to get it to work. The javascript in emo.min.js I had to include inline in my template. If I just left it as a src= link then for some reason it seemed to link to the document template rather than the code.

      Also in a few cases where the link text had a space in it then tinyMCE editor with word wrap on was putting in a carriage return which foxed the plugin.
      <a href="mailto:[email protected]">District Commissioner</a>


      I had to turn off the word wrap in tinyMCE and remove the return characters to get it to work.

      Regards

      Adrian
        • 13428 ☆ A M B ☆
        • 1,031 Posts
        The regex option ’s’ should solve this:

        Quote from: "http://php.net/manual/en/reference.pcre.pattern.modifiers.php"

        s (PCRE_DOTALL): If this modifier is set, a dot metacharacter in the pattern matches all characters, including newlines. Without it, newlines are excluded.
        $part = preg_replace_callback('#<a[^>]*mailto:([^\'"]+)[\'"][^>]*>(.*)</a>#iUus', array($this, 'encodeLink'), $part);

          • 18503
          • 45 Posts
          Thanks for emo - very useful!

          I noticed in Firefox’s error console that on pages with a mailto: link I’m getting a Javascript error "a is not a function" in emo.min.js (line 1)

          For reference: http://rachelheldevans.com/test-blog-article

          The E-mail Obfuscation plugin still seems to be working, so not sure how serious it is (or if anyone has the issue for that matter, could just be me).

          Thanks again,
            -dan
            http://wylio.com
            Wylio - Pictures for Bloggers
            • 10323
            • 35 Posts
            Will there be a Revo version of emo? Would be super...

            Thanks
              • 25511
              • 13 Posts
              Quote from: Marturion at Feb 05, 2011, 12:34 PM

              I noticed in Firefox's error console that on pages with a mailto: link I'm getting a Javascript error "a is not a function" in emo.min.js (line 1)

              I have this same error occuring on one customers pages. Really weird since I use lot of this script (same physical Evo install where emo is included) and it's first site where this happens.

              Did full reinstall on plugin and disabled every other js-code but couldn't get rid of this. Plugin seems to work fine though, but beeing perfectionist, I don't like errors smiley
                • 13428 ☆ A M B ☆
                • 1,031 Posts
                Quote from: Roope at Oct 25, 2011, 05:02 AM

                I have this same error occuring on one customers pages. Really weird since I use lot of this script (same physical Evo install where emo is included) and it's first site where this happens.

                Maybe you have to invoke emo.min.js as the first javascript on the page. emo.min.js has its own onload handler inside (which could be replaced by jQuery or another framework onload handler by modifying the uncompressed file and minify it afterwards).