# How to conditional display fields on a user input form (and dynamically look up helper text / display titles)

**URL:** <https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890>\
**Category:** How do I?\
**Created:** [July 28, 2022, 5:26pm UTC](https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890 "2022-07-28T17:26:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nick\_AMS](https://avatars.discourse-cdn.com/v4/letter/n/58f4c7/32.png) [@Nick\_AMS](https://community.weweb.io/u/Nick_AMS)\
**Post date:** [July 28, 2022, 5:26pm UTC](https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890/1 "2022-07-28T17:26:14Z")

</div>

Hi!

Hoping to get a bit of guidance around how to setup a form on the site I’m building out.

Core concept for this section is that you’d create a policy which contains 10-15 parameters, with that policy then saved in the database to be looked up at a later date.

Idea would be that you first select a policy “type” (of which there are four - 1,2,3,4) at the top of the page. Most of the parameters are common between different policy types, but there are are some differences and need the form to display only the relevant ones depending on the initial policy type selection.

Looking for the parameter entry part to be laid out with the different parameters entered in rows (i.e. as below)

![image](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/a/a7325217a9f769e5a4032ceee9784ce7f5d099d7.png)

**Key questions**

- I’m looking to add on a description for each field, pre-populate some with defaults, have some as free text, some as drop downs, some as on/off (or boolean) values
  - Is there any way I could achieve this from a lookup table rather than setting manually for each cell in WeWeb?
    - Table I’m looking to populate (in XANO) has 20 or so columns

 ![image](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/0/01f321ef92f39c5036b38482fa4f71c5bc6e3a4f.png)

```
    - I’ve written out how I’d want it to work in a GoogleSheet for each of those XANO columns - extract shown in screenshot below

```

 ![image](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/f/fc1cb1a845d09674d083ef2f4aa5c496e71272c0.png)

- Somehow want to be able to have the ‘WeWeb display column name’ (second column) as what’s displayed to the user, the ‘helper text’ appear as mouseover popup, ‘display for policy types’ list specify whether the field appears etc

- Any solutions for getting this table into either WeWeb or XANO and effectively reading from the relevant column to determine what to display on the form?

Any help much appreciated!

Thanks.

Nick

---

<div class="post-metadata">

**Author:** ![dorilama](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/dorilama/32/10403_2.png) [@dorilama](https://community.weweb.io/u/dorilama)\
**Post date:** [July 28, 2022, 5:46pm UTC](https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890/2 "2022-07-28T17:46:18Z")

</div>

Looks like you need to set up your own grid layout and then populate the cells with all the ui elements that you need (select, input ecc) and show them conditionally on your parameters.

For a simple example of a grid layout look here [Dynamically structured data grid element - #2 by dorilama](https://community.weweb.io/t/dynamically-structured-data-grid-element/780/2)

---

<div class="post-metadata">

**Author:** ![Nick\_AMS](https://avatars.discourse-cdn.com/v4/letter/n/58f4c7/32.png) [@Nick\_AMS](https://community.weweb.io/u/Nick_AMS)\
**Post date:** [July 29, 2022, 1:09pm UTC](https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890/3 "2022-07-29T13:09:56Z")

</div>

Thanks dorilama! Will give it a try

---

<div class="post-metadata">

**Author:** ![dorilama](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/dorilama/32/10403_2.png) [@dorilama](https://community.weweb.io/u/dorilama)\
**Post date:** [July 29, 2022, 1:26pm UTC](https://community.weweb.io/t/how-to-conditional-display-fields-on-a-user-input-form-and-dynamically-look-up-helper-text-display-titles/890/4 "2022-07-29T13:26:28Z")

</div>

> [@Nick\_AMS](#):
>
> Will give it a try

Let me know how it goes 🙂
