So I have also built a custom Quickview Popup on the âOur Productsâ page and the Plus and Minus button only work on the 1st product Quickview but not the others. I am wondering why this is? Is it because there are several Add To Cart buttons on the same page?
Noah we would all appreciate you telling us how you achieved this plus and minus button⌠could you possibly give us a quick rundown how you achieved it?
Looks great!
P.S. Would it be possible to insert it next to the add-to-cart button on the collection page?
Sadly this doesnât work anymore. Since in the product page they removed the ID tag. I circumvented with var inputField = document.getElementsByClassName(âquantityâ)[0]; It just doesnât work, I have checked everything, also checked the example. The funny thing is, that also in the life example it doesnât work anymore.
the linkblock for the âplus buttonâ needs to have (plus) set as its element I.D.
the linkblock for the âminus buttonâ needs to have (minus) set as its element I.D.
Now the tricky part is finding the âQuantityâ elements I.D to apply to the code snippet linking everything together correctly.
To find the element I.D of the âQuantityâ element, we need to set the page live. By this I mean, publish the page and view it live in the browser.
Now we need to go to the web inspector / inspect element depending on the browser you are using. This is a developer tool that allows us to view the code.
Then when you have the web inspector open, select the âQuantityâ element with the number figure in it (on the page). Once you have selected this, the corresponding section of HTML code will be highlighted. Within this HTML there will be an element I.D with the # symbol before it. You need to copy the I.D which should read something like this âquantity-5653eb496f4e8e5489bceb6448510ee2â.
Double click this to select it, apply to the custom code snippet and you should be good to go. Assuming you follow all of the additional class name steps that is.