Sold Out Button to only show when all variants sold out

Highlighted
New Member
2 0 0

I am new to coding, and really only learning to made some changed on my new website. My theme did not come with a sold out banner so i added it into the code this way:

 

I inserted copied the coming soon code and changed it to sold out, and added sold out to the language coding.

 

Screen Shot 2020-04-02 at 12.39.04 PM.png

 

Now, I need it to only show the sold out banner when ALL variations are sold out. 

0 Likes
Highlighted
New Member
2 0 0

I have added this code and it seems to be working correctly for non-variant products but the banner is not showing on products with variants that all variants are sold out.

 

 

 Screen Shot 2020-04-02 at 2.53.53 PM.png

0 Likes