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.
HI
I have a number of hidden fields on a multistep webform I've created. While these hidden fields are not displayed on the form, they are displayed on the Preview page. Should they not be hidden on the Preview page as well?
I tried placing the hidden fields in a Container and adding a css class to that container, so I could hide it with CSS, but the class is not being applied to the container in the HTML on the Preview page, so I can't hide them.
Any ideas?
Thanks
F
Comment | File | Size | Author |
---|---|---|---|
#7 | hidden_element_are-2889694-7.patch | 795 bytes | jrockowitz |
| |||
#5 | hidden_element_are-2889694-5.patch | 0 bytes | jrockowitz |
Comments
Comment #2
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedI agree that hidden and value elements should not be visible on the preview page.
An immediate workaround is to #2888615: Allow preview to exclude elements
Comment #3
frankdesign CreditAttribution: frankdesign commentedThanks jrockowitz
Just updated to the dev version to access the Preview page include/exclude options for each field. Works a treat.
However as a side note, I notice that the code output for the progress bar has been completely changed in the Dev module. Is that the way the main module is going to go? If it is, I might as well update my CSS now. Let me know
Thanks
F
Comment #4
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedThe new progress bar is using https://nigelotoole.github.io/progress-tracker/ which can be disabled under Admin settings which will revert the progress bar to the old basic design.
Comment #5
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedI reviewed the Webform module for D7 and it displays hidden and value elements on the preview page and lets you hide it via the preview settings. The one thing missing from D8 was the ability to set a #title for hidden and value elements. The attached patch fixes this.
Comment #7
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #9
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commented