Hi everybody,
I have searched these forums and the old one, along with netsuite's documentation and I cannot seem to get an answer/guide to do this. I would like create a custom item template that displays a modified add to cart button.
I want the "qty to add to cart" box to appear on specific items only. Since you can only define one add-to-cart html template under setup -> website -> website themes I think the best way of doing this would be to create a custom item template with the actual code for adding an item to the cart, as you might use in an external wsdk site.
I was given code a while back by our implementer that would draw a working add-to-cart button. The problems are (1) it doesn't display the item options for matrix items, and (2) it doesn't contain a qty box. The code is as follows:
[SIZE=2] <form method="post" name="form<%=getCurrentAttribute("item", "internalid")%>" id="form<%=getCurrentAttribute("item", "internalid")%>" action="/s.nl;jsessionid=ac112b791f432f7f6dd17b3744dbbbfcf12f4c4feacfe3eTaxeKbh0Te3iMahqTbNqSai1ynknvrkLOlQzNp65In0" onSubmit="return checkmandatory<%=getCurrentAttribute("item", "internalid")%>();"> <input name="c" value="210436" type="hidden"> <input name="sc" value="2" type="hidden"> <input name="category" value="5" type="hidden"> <input name="id" value="<%=getCurrentAttribute("item", "internalid")%>" type="hidden"> <input name="it" value="A" type="hidden"> <input name="referer" value="http://shopping.netsuite.com/s.nl?c=210436" type="hidden"> <input name="buyid" id="buyid" value="<%=getCurrentAttribute("item", "internalid")%>" type="hidden"> <input src="/site/images/buttons/addtocart.gif?id=<%=getCurrentAttribute("item", "internalid")%>&c=210436&h=5cc05031bc713b22395e&_xd=T" style="border: 0pt none ;" id="addtocart" name="addtocart" onClick="if (document.forms['form<%=getCurrentAttribute("item", "internalid")%>'].onsubmit()) document.forms['form<%=getCurrentAttribute("item", "internalid")%>'].submit();return false;" type="image"> </form>
[/SIZE]
I've tried adding the qty box and item options using the netsuite tags to no avail. Does anyone here know what I need to add to this code to display (1) the item options drop down for matrix items and (2) the qty box?
Thanks in advance!