# Allow Display Rules for Static Elements

**URL:** <https://forums.knack.com/t/allow-display-rules-for-static-elements/11528>\
**Category:** Feature Requests\
**Created:** [November 10, 2021, 3:05pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528 "2021-11-10T15:05:00Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Roman](https://avatars.discourse-cdn.com/v4/letter/r/ed8c4c/32.png) [@Roman](https://forums.knack.com/u/Roman)\
**Post date:** [November 10, 2021, 3:05pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/1 "2021-11-10T15:05:00Z")

</div>

It would help to hide/show Static Elements based on form values. Sometimes the “static elements” / instructions need to change based on the user input.

When the fields are being hidden/shown based on form values, we need the option to hide/show the static elements that contain the instructions for the user.

---

<div class="post-metadata">

**Author:** ![Johnny\_Appknowledged\_UK](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.knack.com/johnny_appknowledged_uk/32/2898_2.png) [@Johnny\_Appknowledged\_UK](https://forums.knack.com/u/Johnny_Appknowledged_UK)\
**Post date:** [November 11, 2021, 3:11pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/2 "2021-11-11T15:11:45Z")

</div>

Hey Roman,

By elements I guess you mean other views? You can easily to this with JavaScript and jquery you can use the change or keyup function and then call the hide or show based on the value of the input.

If you need help with this Message me  
[Johnny@appknowledged.co.uk](mailto:Johnny@appknowledged.co.uk)

---

<div class="post-metadata">

**Author:** ![Roman](https://avatars.discourse-cdn.com/v4/letter/r/ed8c4c/32.png) [@Roman](https://forums.knack.com/u/Roman)\
**Post date:** [November 11, 2021, 7:59pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/3 "2021-11-11T19:59:49Z")

</div>

Hi Johnny, thanks for your reply. By “static elements” I meant Title text and dividers. Currently the rules only seem to apply to other fields, not objects that arent fields. I’m not a coder, so I’m only using the drag and drop features.  
 ![Screenshot 2021-11-11 115936](https://us1.discourse-cdn.com/flex020/uploads/knack/original/2X/8/832f44b82924424e51f3aa57d19cf95b8ebde93a.png)

---

<div class="post-metadata">

**Author:** ![Roman](https://avatars.discourse-cdn.com/v4/letter/r/ed8c4c/32.png) [@Roman](https://forums.knack.com/u/Roman)\
**Post date:** [November 11, 2021, 8:11pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/4 "2021-11-11T20:11:38Z")

</div>

Hi Johnny,

Thanks for your reply.

By “static elements” I meant Title Text and Dividers. Currently the rules only seem to apply to other fields, not objects that aren’t fields.

I’m not a coder, so I’m only using the drag and drop features. Perhaps you can teach me how to code this.

![Screenshot 2021-11-11 115936.png](https://us1.discourse-cdn.com/flex020/uploads/knack/original/2X/8/832f44b82924424e51f3aa57d19cf95b8ebde93a.png)

![image002.png](https://us1.discourse-cdn.com/flex020/uploads/knack/original/2X/0/09e7478fc05887eae0f7066f45717158e508b362.png)

---

<div class="post-metadata">

**Author:** ![HGSU](https://avatars.discourse-cdn.com/v4/letter/h/848f3c/32.png) [@HGSU](https://forums.knack.com/u/HGSU)\
**Post date:** [January 9, 2022, 10:19pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/5 "2022-01-09T22:19:54Z")

</div>

I would also love to see this feature added. The “Instructions” option for individual questions can be one alternative, but those appear underneath the question itself, and I wanted my instructions to appear before the users gets to the answer selection. The workaround I found that works pretty well is to basically take all of the text I wanted to be in the static field and add it to the “Label” field of the question it goes with. Knack will automatically make all of this text in to a bolded “header”-type text, but you can make it look and read like basic text in a static field using some simple HTML formatting codes (e.g. add \<br /\> to create line breaks, or put in \<span style=“font-weight:normal;”\> and all the text that appears after the \> will look like normal text. This is a bit clunky and difficult to edit because the “label” boxes are one-liners, but it gets the job done for now.

---

<div class="post-metadata">

**Author:** ![GaryStark10384](https://avatars.discourse-cdn.com/v4/letter/g/e95f7d/32.png) [@GaryStark10384](https://forums.knack.com/u/GaryStark10384)\
**Post date:** [May 11, 2022, 1:04pm UTC](https://forums.knack.com/t/allow-display-rules-for-static-elements/11528/7 "2022-05-11T13:04:12Z")

</div>

@HGSU thanks for your input here. What field type do you use when you do your suggestion? Since it’s really the label that matters, I don’t want the form field to confuse the user. Thanks!!
