Swapping Add to Cart button text if tagged with 'waitlist'

Solved
Highlighted
Tourist
28 0 1

Hi there, I am trying to change some add to cart button logic to display the word "waitlist" instead of sold out if the product is tagged with waitlist. Here is my code: 

<button
        class="add-to-cart caps futura"
        type="submit"
        name="add"
        data-add-to-cart
        {% unless current_variant.available %}disabled="disabled"{% endunless %}>
          <span data-add-to-cart-text>
            {% if current_variant.available %}
Add To Cart
{% elsif product.tag contains 'waitlist' %}
Waitlist
{% else %}
Sold Out
{% endif %} </span> </button>

 

I feel like there is some glaring mistake that I'm making. Help would be greatly appreciated.

 

Thanks!

0 Likes
Highlighted

Success.

Shopify Partner
1206 162 330

Just missing an "s". Use product.tags, not tag

If my solution helped you, please like and accept as solution!
If you'd like to make any edits to your store, please send me a personal message and we can discuss what you'd like to accomplish :D
0 Likes
New Member
1 0 0

Where exactly does this code go? 

 

0 Likes