Required Text Field not forced

Solved
SandysFabricsTC
Tourist
3 1 0

Ive been working on this and googling for a bit now. I still have had no luck. I'm trying to make a simple required text field where they input what machine before it adds to cart. Doesn't seem to work.

 

<div class="payment-buttons payment-buttons--{{ section.settings.add_to_cart_button_size }}">
<p class="line-item-property__field">
<label for="what-machine-are-you-bringing">What machine are you bringing?</label>
<input required class="required" id="what-machine-are-you-bringing" type="text" name="properties[What machine are you bringing?]">
</p>
<button type="submit" name="add" id="addToCart-{{ section.id }}" class="{{ btn_class }} btn--add-to-cart{% if section.settings.enable_payment_button %} btn--secondary-accent{% endif %}">

<span class="icon icon-cart"></span>
<span id="addToCartText-{{ section.id }}">{{ 'products.product.add_to_cart' | t }}</span>
</button>

{% if section.settings.enable_payment_button %}
{{ form | payment_button }}
{% endif %}

 

It does not check if the box is filled and allows to proceed. Any help?

 

Website: 

https://sandysfabrics.com/products/serger-instruction-i-ii-june-8th-10-00-am-1-00pm?variant=37709223...

0 Likes
SandysFabricsTC
Tourist
3 1 0

Site added

0 Likes
SandysFabricsTC
Tourist
3 1 0

This is an accepted solution.

SOLVED IT! Added to code in a <form> field!

0 Likes