• Resolved Guss77

    (@guss77)


    When email is sent from WooCommerce, and the locale is set to he_IL, emails arrive with question marks instead of any Hebrew character.

    Using WordPress 4.3.2 with WooCommerce 2.4.12 on Debian 8 with PHP 5.6.15. Email is sent via SMTP using Easy WP SMTP.

    I’ve traced the problem to the use of Emogrifier by the WooCommerce class-wc-email.php file, and it looks to be the PHP DomDocument implementation that goes crazy when UTF-8 encoded HTML is submitted to DOMDocument::loadHTML when it contains HTML meta tags with encoding specification.

    There are several documented workarounds and it looks like the latest version of Emogirifier (from https://github.com/jjriv/emogrifier ) implements the required workarounds. I’ve dropped in the latest version instead of the one currently in WooCommerce – without any changes except that I had to remove the namespace decleration – and it worked out of the box and solved the problem.

    https://www.ads-software.com/plugins/woocommerce/

Viewing 1 replies (of 1 total)
  • Guss77, you’re angel!
    This problem turned into a nightmare for me and read whole of the internet, nothing else worked. Though you’ve written the solution very concise and professionally with no details, but I broke the code and at last, your solution worked!

    Many Thanks

Viewing 1 replies (of 1 total)
  • The topic ‘Emails sent from WooCommerce in Hebrew arrive with question marks’ is closed to new replies.