Closed (fixed)
Project:
Webform
Version:
4.7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Jul 2007 at 18:50 UTC
Updated:
1 Nov 2007 at 06:13 UTC
Just like the subject line says. In a webform with an email component, under the options for From Name and From Email, the choices are the reverse of what they should be. I've attached a patch to fix this. The offending block is at line 588:
if (is_array($node->webformcomponents) && !empty ($node->webformcomponents)) {
foreach ($node->webformcomponents as $cid => $component) {
$type = $component['type'];
/* This is wrong -- the first one should be email */
if (in_array($type, array('textfield', 'hidden', 'select'))) {
$possible_email_from_address[$component['name']] = $component['name'];
}
/* This is wrong -- the first one should be textfield */
if (in_array($type, array('email', 'hidden', 'select'))) {
$possible_email_from_name[$component['name']] = $component['name'];
$possible_email_subject[$component['name']] = $component['name'];
}
}
}
| Comment | File | Size | Author |
|---|---|---|---|
| webform_19.patch | 870 bytes | chellman |
Comments
Comment #1
davemybes commentedJust noticed the same issue, and that's exactly the patch I did to the module. Good job on this patch.
Comment #2
quicksketchThanks, this issue has been corrected in 5.x already. I've applied your patch, but 4.7 is no longer being supported and no new releases of webform will be created for 4.7. I'd highly suggest getting your sites onto 5.x if possible. Thanks!
Comment #3
(not verified) commented