# input field validation

**URL:** <https://community.hubspot.com/t/input-field-validation/17335>\
**Category:** CMS Development\
**Created:** [November 21, 2019, 12:24pm UTC](https://community.hubspot.com/t/input-field-validation/17335 "2019-11-21T12:24:10Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [November 21, 2019, 5:09pm UTC](https://community.hubspot.com/t/input-field-validation/17335/2 "2019-11-21T17:09:38Z")

</div>

You’d probably want to use something like this:

```auto
{% if widget_data.product_names.value %}
<div class="coupon-ad">
<h3>For a limited time, get 50% off {{ widget_data.product_names.value}}! </h3>
</div>
{% else %}

{% endif %}

```

Further information is available here: [If statements - HubSpot docs](https://designers.hubspot.com/docs/hubl/if-statements)

---

_[View the full topic](https://community.hubspot.com/t/input-field-validation/17335)._
