PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Gravity forms 1.6 list feature with more advanced elements (drop downs etc.)

  1. Hi guys,

    Is there a way to have more complex elements "nested" within the new G1.6 list type??

    For example, a list type form element where, rather than simple text fields, there are drop down boxes which can be duplicated - now that would be great :) [I.e. it would be great to be able to group form elements then duplicate these groups on the fly as the form is filled out .. ]

    Thanks in advance!
    Andrew

    Posted 13 years ago on Thursday November 10, 2011 | Permalink
  2. By default the List Field only works with text inputs. It does also support drop downs, but only through the use of a hook.

    The UI kind of limits what can be presented in the form editor because you get into the issue of having a field editor within a field editor once you introduce a drop down like that. So we implemented it as a hook.

    The hook is documented here:

    http://www.gravityhelp.com/documentation/page/Gform_column_input

    Currently it only supports drop down fields as an additional input type. However, we do plan on enhancing this in the future to support some other field types that may make sense.

    Posted 13 years ago on Thursday November 10, 2011 | Permalink
  3. Thanks Carl - much appreciated mate - worked nicely

    2 final questions on this point though:

    1. How would I enable the "enhanced user interface" for these list nested drop downs

    2. Can I (in the list) setup a dynamic drop down dependent on the selection in the first drop down using hooks?

    Posted 13 years ago on Friday November 11, 2011 | Permalink
  4. The enhanced interface isn't currently an option for these list nested drop downs, it's only an option on the Drop Down field type itself. We can look at enhancing this in the future.

    Conditional logic will not be usable within the individual drop downs of the list items. They aren't Gravity Forms field types so there is no way to do this.

    The List Field is brand new so we will continue to enhance it going forward.

    Posted 13 years ago on Friday November 11, 2011 | Permalink
  5. Richard Vav
    Administrator

    It may be possible to enable the enhanced interface for list field drop downs and all it takes is a little bit of jquery. Normally you would target the dropdown itself but because the list field drop downs aren't assigned an id or class you can't target them directly instead you have to target the parent element then include the child element type .

    So in this example I am applying the enhanced ui to the dropdowns (select's) in columns 4 and 5 by targeting the class of the cell they are contained in.

    $('.gfield_list_37_cell4 > select, .gfield_list_37_cell5 > select').chosen({no_results_text:'No results matched'});

    Posted 12 years ago on Sunday November 27, 2011 | Permalink
  6. sascha
    Member

    Hi Richard,
    so does that Jquery code give us the enhanced interface for dropdowns in list fields?
    Have you got a more elaborate example? I am not 100% sure where to put the Jquery code and how to find out which fields exactly to target....

    Posted 12 years ago on Sunday November 27, 2011 | Permalink
  7. Richard Vav
    Administrator

    Hi sascha,

    In theory that bit of jquery placed between <script> </script> tags above or below the form should enable the enhanced ui for a drop down (select) in a list field, I say in theory just like I said 'it may be possible' above because I haven't had a chance to test it out yet. It should definitely work on a drop down in the first row, it should also enable the appearance of the enhanced ui on subsequent rows. The only thing I can't gaurantee is that the drop downs on the subsequent rows will pass the selected item back to the actual field behind the enhanced mask, that may take a bit more coding to get working if it doesn't.

    All that said what you have to remember is that the list field is still new and no doubt the guys already have plans for how they can enhance/extend the list field functionality in future updates, and maybe the enhanced ui will get worked in at some point as an option in the hook.

    Posted 12 years ago on Sunday November 27, 2011 | Permalink

This topic has been resolved and has been closed to new replies.