Hi! I ran into an odd little problem today. When downloading results for MS Excel, if I choose the "separate" select list option, I will get the KEYS regardless of my selection under "select keys." The "compact" format works as expected when human-readable values are requested.

Out of curiosity, I also tried this with the delimited text export format, and it appears to have the same result. I've been able to duplicate this on a few different webforms which use the select component.

Thanks in advance for any help you can offer, and please let me know if there's more information I can provide.

CommentFileSizeAuthor
#4 webform-excel.patch624 bytesretorque
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

quicksketch’s picture

Thanks for the report, I'll take a look next time I'm going through the issue queue.

retorque’s picture

I'm still testing, but it looks like if you replace line 664 ($headers[2][] = $key;) with the below code segment in compontents/select.inc, the full text is displayed.

if ($export_options['select_format'] == 'separate') {
$headers[2][] = $item;
} else {
$headers[2][] = $key;
}

I am currently working with version 6.x-3.4, not with the current dev version, so the line number may be different there. Unfortunately, it looks like my recent upgrade may have caused a data problem as well, so I'm not going to be able to create a patch until I get that fixed. If someone else has time to create a patch, please do.

retorque’s picture

Note to self: Fully test before posting comments.

Try the below code segment instead of the one I posted a few minutes ago:

if ($export_options['select_keys']) {
$headers[2][] = $key;
} else {
$headers[2][] = $item;
}

retorque’s picture

FileSize
624 bytes

Here is a patch against HEAD.

This modifies the _webform_csv_headers_select() function.

quicksketch’s picture

Status: Active » Fixed

Thanks committed to both 3.x branches.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.