Posted - 08/12/2019 : 15:52:01
Maybe I'm trying to do something the wrong way, but.... in a custom aspx page I create the new product price and set the product options. The first time pass the values, the cart inserts correctly. "custom" The second product added for that session, adding the same product CardId ("custom") the previous cart entries get added, along with a new cardID and associated cartoptions, but the price of each item in the cart change together to the last price.
<form name="CustomQuote" action="cart.asp" method="post"> <input type="hidden" value="add" name="mode" /> <input type="hidden" value="default.aspx" name="frompage" /> <input type=hidden value=<%=strCustomXXX%> name="id" /> <input type="hidden" value="264" name="optn0" /> <input type=hidden value="<%=strFontColorName%>" name=voptn0 />
<input type="hidden" value="40" name="optn1" /> <input type=hidden value="<%=strFontName%>" name=voptn1>
<input type="hidden" value="18209" name="optn2" /> <input type=hidden value="<%=strFontSize%>" name=voptn2 />
<input type="hidden" value="18008" name="optn3"> <input type=hidden value="<%=strChars%>" name=voptn3 /> <input type="hidden" value="19050" name="optn4"> <input type=hidden value="<%= strCustomXXX&".pdf" %>" name=voptn4 />
<p align="center"><input type="submit" value=" Submit Order " name="CustomQuote"></p> </form> Price is passed as Dim dPrice As Double = Val(Session("dPrice"))
in inccart.asp line 2196 or so (sSQL="INSERT INTO cart *****) I see the price of the additional product is fine. after the function additemtocart(ainame,aiprice) is done, the code goes off someplace to update the cart. At that time the cart count summary shows each item '1 x custom quote" at the last price.
You can test the code at https://wallwordsdev.visualnetmedia.com/ "Design Your Own" Type a word. step 2 select font size, step 3 select color, then add to cart. Then confirm on next page.
Why or where is the cart code changing the price of all items in the cart? How to prevent this?
|