On the preview page, conditional selections (checkboxes) that are dependent on showing only when another selection is chosen, will always show on the preview display page regard less of whether they are selected by the user on the form or not, either as a blank space or the actual text. This is not happening with standard selections (checkboxes).

I know the conditional sets are selected under "INCLUDED PREVIEW VALUES" under 'form settings' >> 'preview' but so are all other selections (checkboxes) and they have no problem disappearing or reappearing on the preview page when appropriate, as the user selects on the form.

There is also something really buggy with the conditionals page. I have several of the following related errors stating "A circular reference involving For myself was found." and I'm sure my conditionals are correct. I tried a patch that did not solve the problem, is this fixed somewhere on stable versions?

CommentFileSizeAuthor
#6 drupal4.jpg93.75 KBdru pal
#6 drupal3.jpg69.05 KBdru pal
#6 drupal2.jpg88.16 KBdru pal
#6 drupal1.jpg57.9 KBdru pal

Comments

Dru Pal created an issue. See original summary.

danchadwick’s picture

Priority: Major » Normal
Status: Active » Closed (cannot reproduce)

Please read the issue queue guidelines for the definition of priority. Overstating the priority of an issue just makes the maintainer's job harder.

I created three Select components with multiple options (so that they are checkboxes). I made the first show the second and the second show the third. I set the webform to preview. Every combination worked perfectly on the preview page.

Please supply DETAILED instruction to reproduce the issue you have having.

But FIRST, if Webform is complaining about a circular reference, then YOUR WEBFORM CONFIGURATION IS BROKEN. Webform isn't broken, your webform is. First fix that as proper operation cannot be guaranteed when their is a dependency circle.

Also, please test with the latest dev. There is no point in investigating bugs which may have already been fixed.

dru pal’s picture

Did you place the three Select components in tiered fieldsets or are they all on the same level pointing to one parent? If not can you elaborate how you nested each selection checkbox?

I just created a test page with three select components (multiple select checkboxes with only one choice ) and placed select component 1 select option (in a fieldset) is on the level above the other two that are within a fieldset as well.

So for example,

Selection 'A' fieldset
>> Selection 'A' checkbox
>>>> Selection 'B' fieldset
>>>>>>>> Selection 'B1' checkbox (separate component)
>>>>>>>> Selection 'B2' checkbox (separate component)

The conditional set is like so.
IF: >> Selection 'A' checkbox is EMPTY
THEN >>>> Selection 'B' fieldset
ISNT SHOWN

I no longer get the "Circular Reference" Error but the selection chechboxes options still show on the Preview results page whether they are selected or not. They will show as a blank space when not selected, I can still see the component in the source code. As you can see it still shows on the preview page but the text does not even show between the element tag div class.

<div class="form indent-form form-item webform-component webform-component-display webform-component--checkbox-fieldset--checkbox-B1">
  <label class="element-invisible" for="edit-submitted-checkbox-fieldset--checkbox-B1">B1</label>
  
</div>

The point of all this is that I need to place the selected options checkboxes in a bullet list but the bullets points still show on the preview page with out the words even if those answers aren't selected. I added the bullets using css. Can you point to the right file and code to implement this in web form? Bullets show up for standard non-conditional bullets but not nested conditional bullets.

I believe to make the change, I need to do something similar to below to get it to work but no success. For one it seems "submitted" should be be "preview"?

https://www.drupal.org/node/79086

http://stackoverflow.com/questions/8877763/drupal-surround-specific-webform-elements-with-a-div

function phptemplate_webform_form_50 ($form) {
  $form['submitted']['First Name']['#id'] = 'edit-submitted-first-name';
  $form['submitted']['Last Name']['#id'] = 'edit-submitted-last-name';
  $form['submitted']['Fluent in']['#id'] = 'edit-submitted-fluency';
  return _phptemplate_callback('webform_form_50', array('form' => $form));
}
dru pal’s picture

Version: 7.x-4.10 » 7.x-4.x-dev
Status: Closed (cannot reproduce) » Active
danchadwick’s picture

Status: Active » Postponed (maintainer needs more info)

You didn't mention anything about fieldsets in your original issue.

I just followed your description as best I could and did not reproduce the issue.

I suggest you post some screen shots of your components, conditionals, submission page, and preview page.

I'm thinking you may have some other module or theme that is causing your issue.

dru pal’s picture

StatusFileSize
new57.9 KB
new88.16 KB
new69.05 KB
new93.75 KB

Attached are screenshots, as you can see in the first image (drupal 1) although I added css for the bullets to show, the bullet for checkbox B2 wouldnt show if the checkbox code wasnt still being included in the source code even though the user didnt select the checkbox in the first place (checkbox B2).

dru pal’s picture

Status: Postponed (maintainer needs more info) » Active
danchadwick’s picture

Category: Bug report » Support request
Status: Active » Fixed

Looks like your theme is making the hidden items show. If you believe webform can be improved to support your theme, please reopen with a patch.

silurius’s picture

Dan, would you mind expounding on the theme hypothesis? I am also struggling with failed hide/show behaviors and had not considered the possibility of my theme being a part of the equation.

Status: Fixed » Closed (fixed)

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