Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
There's a line of code in webform_format_email_address that causes submissions to display a warning message when a form is submitted and the form is set up to email a component value.
Line 4317 of webform.module
foreach ($name as &$one_name) {
$name = isset($options[$one_name]) ? $options[$one_name] : $name;
}
Since name begins the foreach as an array, but is converted to a string, the foreach barks the warning. This might be related to specific version of PHP, I'm using 5.5.27.
Comment | File | Size | Author |
---|---|---|---|
#3 | webform-webform_format_email_address_warning-2535378-3.patch | 1 KB | DanChadwick |
#1 | invalid_argument_in-2535378-1.patch | 2.16 KB | delzhand |
Comments
Comment #1
delzhand CreditAttribution: delzhand at Alloy Magnetic commentedSolution attached.
Comment #2
delzhand CreditAttribution: delzhand at Alloy Magnetic commentedComment #3
DanChadwick CreditAttribution: DanChadwick commentedThanks for the report. The problem is that the code isn't doing what it should, rather than is using PHP in a version-specific way. I'm not sure if the bug could ever cause a functional issue, but now it's fixed regardless.
Fixed in 7.x-4.x and 8.x.