I have a four page webform that only has introductory markup on the first page. When attempting to edit the submitted form, I can never proceed off of the first page. This appears to be due to the fact that the webform_client_form function uses the submitted array in the form_state as an indication that it is proceeding through a multi-page form:
// Check if we're in a multipage form and determine the page number.
if (!empty($form_state['storage']['submitted'])) {
but the webform_client_form_submit function only seems to create this array if actual fields existed on the page that was submitted:
// Store values from the current page in the form state storage.
if (is_array($form_state['values']['submitted'])) {
foreach ($form_state['values']['submitted'] as $key => $val) {
$form_state['storage']['submitted'][$key] = $val;
}
}
Creating a hidden field on the markup-only page seems to work around the problem, but this was a very frustrating problem for me especially as I poured through the bug submissions and saw everyone moving merrily past their form editting problems on to bigger and better things. I'm very new to Drupal and don't know the FAPI well enough to suggest or implement a proper fix.
Comments
Comment #1
quicksketchThanks TMSA, that's an excellent report. I'll try to see what kind of solution I can come up with.
Comment #2
quicksketchJust a note that this was fixed as a side-effect of the new page handling added in #254728: Conditional fields.