Support » Plugin: Email Encoder - Protect Email Addresses and Phone Numbers » eeb_email_filter() removed?
Have you guys disabled the support for the template function eeb_email_filter() in the latest version? This case causes extensive problems since I have used the function in dozens of different websites. Could you kindly add backwards compatibility to this, it’s really important.
Hey @delanet / thank you for your message and sorry to hear that you face issues.
We haven’t removed the eeb_email_filter function, but we deprecated some of the other parameters to keep up with the dynamic.
You will find it’s definition here: https://plugins.trac.wordpress.org/browser/email-encoder-bundle/trunk/core/includes/functions/template-tags.php
Could you please share more details on what issue you face?
I would love to help you with sorting that out.
Thanks already a lot.
Well, after upgrading from 1.53 to 2.0.0, my site will stop working.
Uncaught Error: Call to undefined function eeb_email_filter ()
Uncaught Error: Call to undefined function eeb_email ()
Applies to both of these functions. Changing the plugin settings does not seem to have any effect.
Got it – can you tell me where you use these functions in your code?
I will then try to reproduce your issue.
For example, in this case, the error simply occurs when I try to call a function in template files like page.php:
<?php echo eeb_email_filter(‘email@example.com ‘); ?> causes a fatal error.
Hey @delanet – thanks for all the information. I just pushed a new version. Feel free to try it and if it still doesn’t work, I’m very happy to help.
Yes, Thank you. Now that seems to work again.
However – what I want is to manually control the context in which email protection is done. This new version also seems to affect email addresses written to template files manually (even if you don’t use any function to print it) as plain text. This should be this new “full page scan” mode.
But when I change it to “Don’t do anything.” option, those functions will also stop working. I think that they should still work just like before.
Thanks for your feedback @delanet – Regarding the other two things:
Control the context manually:
We removed this functionality since it caused a lot of trouble before. This is the case because we need always need to soft encode certain parameters and validate others in a certain pattern to keep up the functionality of the site.
If you are aware of that and you still would like to use your own functions, you can use our encoding specific functions to encode your emails in the way you want.
Here are some of them as an example:
EEB()->validate->filter_input_fields('<input value="firstname.lastname@example.org" />')
This function will encode your input values. The setting within the plugin for
using the strong protection for input fields is still influencing this output.
EEB()->validate->filter_mailto_links('<a href="mailto:email@example.com">This is a text email firstname.lastname@example.org</a>')
This function allows you to filter all mailto links within a given context.
EEB()->validate->filter_plain_emails( 'This is a text email email@example.com', null, 'char_encode' )
With this one you will encode all given emails using the
Regarding your other topic that these functions should work also when you deactivate the default logic: You are right with that.
I included a pre-version down below that removes the limitation of the availability of some functions after deactivation.
Feel free to download it here: https://www.dropbox.com/s/nub1v9v8agpuaym/email-encoder-bundle.zip?dl=1
Hi @delanet – We just pushed a new version yesterday that also addresses your second issue. All the shortcodes will be now also available after deactivating the plugin functionality itself.
Feel free to reach out in case you need further help.
Hey @delanet – thanks for your message. I will include a fix for that into our next version.
Feel free to download your beta version here: https://www.dropbox.com/s/1kah55xh78vo3q3/email-encoder-bundle-delanet.zip?dl=1
This version addresses a fix for your problem and will continue to work after updating to the upcoming versions of this plugin.
Based on a quick test, the beta version seems to work OK. However, I am awaiting the official version which fixes this issue. Until then, I use the familiar and secure version 1.53 on all my sites.
Now tested with 2.0.3 and STILL NO GOOD.
With the “Don’t do anything.” -setting enabled and trying to echo an invidual email address with eeb_email($email), the function returns the string to the wrong place in the HTML structure, not exactly where I want it. (Instead, the eeb_email_filter () function places the bounce string in the right place, but I have dozens of sites that use the eeb_email () function, so changing all of these is not a solution.)
Why is it so hard to get this to work the same way and fully backwards compatible as in version 1.53 🙁
- This reply was modified 2 years, 9 months ago by delanet.
Hi @delanet – thank you for your message and sorry to hear that you still face issues.
I checked again on that topic and the problem is that the content sent directly to the output instead of returning it.
I created a new version that addresses this issue here: https://www.dropbox.com/s/2e5ra1va13m9ylb/email-encoder-bundle-delanet.zip?dl=1
Feel free to test with it. If it works for you, you can continue using it since I will push the same logic within the next launch of the version. You can then simply update and it continues to work.
That should be the last issue – I tested it as well from my end and it appears on the right spot.
Please let me kow if you need anything else.
I just tested the beta and this issue seems to have been fixed. Thanks for that. I will wait for the official new version before making any major updates to all my sites.
- The topic ‘eeb_email_filter() removed?’ is closed to new replies.