PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Email Notification Formatting Issue & Solution

  1. bankofcanada
    Member

    I was experiencing some issues with email notifications, specifically when including multi-column list fields. Spaces were being inserted into the HTML, causing tags and styles to appear broken.

    I did some research and found that when a single line exceeds 998 characters, it causes problems with the PHP mail function.

    I fixed it by making this change to common.php, on line 1665:

    $is_success = wp_mail($to, $subject, $message, $headers, $attachments);

    was changed to

    $is_success = wp_mail($to, $subject, wordwrap($message), $headers, $attachments);

    Due to the way the email messages are assembled via string concatenation without any built in line breaks, I can only assume that other users must have encountered this issue as well. Would it be possible to add the wordwrap() into the next Gravityforms release?

    Thank you!

    Posted 5 years ago on Tuesday July 9, 2013 | Permalink
  2. Richard Vav
    Administrator

    If you still require assistance with this please open a new support ticket or a priority support ticket if you are a developer license holder. Thank you.

    Posted 5 years ago on Thursday July 25, 2013 | Permalink

This topic has been resolved and has been closed to new replies.