Hi, I am trying to remove the quantity from my products since we are selling one of a kind pieces. Can someone walk me through this. New to coding.
Thanks!
URL is authenticluxuries.com
Hi, I am trying to remove the quantity from my products since we are selling one of a kind pieces. Can someone walk me through this. New to coding.
Thanks!
URL is authenticluxuries.com
I donât think you can remove quantity entirely, as this information is needed when someone makes a purchase. There is a couple of ways to achieve this:
To disable the quantity button, so it defaults to 1.
Hidden it from customerâs view
The changes are quite simple, but if you donât know anything about Liquid or coding, then it could be a bit dangerous as you need to be able to navigate to the right section of the code. The main-product.liquid file is fairly fundamental to the working of your shopify shop, so please make sure you know what you are doing before doing it. Let me know if anything is not clear.
To achieve option 1, all you need to do is to go to your code editor, and find âmain-product.liquidâ file from Section, and then replace the relevant code block with the following. I have highlighted the relevant changes in red. The 1st and last bit disables the code for the + and - buttons. You could just remove these sections from your code entirely if you think you never want it.) The middle change (i.e. readonly in red) is to make the quantity box read only so your customer cannot change the default.
{%- when âquantity_selectorâ -%}
ps. I just remembered, you would need to do the same in the cart page, which can be found in main-cart-items.liquid.
Hi @HCKinard ,
You can simply disable the quantity selector on your product pages from your theme editor:
From your Shopify admin, go to Sales channels > Online store > Themes > Customize
From the page selecting menu, select Product Pages > Default product
Click on the eye button beside the quantity selector to disable it
I hope it helps.