close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

eCart not passing Discount to PayPal

Thread began 12/14/2011 7:53 am by Nathon Jones Web Design | Last modified 10/16/2013 11:36 am by Nathon Jones Web Design | 2805 views | 14 replies

Nathon Jones Web Design

eCart not passing Discount to PayPal

We're using ASP/VBScript, DW 8.0.2 and eCart 4.5.2.

We have the following form submitting to PayPal from our view-basket.asp page:

<form action="" method="post">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="upload" value="1">
<input type="hidden" name="business" value="">
<%SFCcart_Index = SFCcart.DisplayIndex - 2%>
while (NOT WA_eCart_EOF(SFCcart))
<%SFCcart_Index = SFCcart_Index + 1%>
<% 'WA eCart Validation
if ((WA_eCart_FormatNumber(WA_eCart_DisplayInfo(SFCcart, "Price") - ((WA_eCart_DisplayInfo(SFCcart, "Price")/WA_eCart_TotalColumn(SFCcart, "TotalPrice")) * WA_eCart_GetDiscounts(SFCcart)), false, 2) > 0)) then
<input type="hidden" name="item_name_<%=SFCcart_Index+1%>" value="<%=WA_eCart_DisplayInfo(SFCcart, "Name")%><%IF WA_eCart_DisplayInfo(SFCcart, "Colour") <> "" Then%>&nbsp;(<%=WA_eCart_DisplayInfo(SFCcart, "Color")%>)<%End IF%><%IF WA_eCart_DisplayInfo(SFCcart, "Size") <> "" Then%>&nbsp;(<%=WA_eCart_DisplayInfo(SFCcart, "Size")%>)<%End IF%>">
<input type="hidden" name="amount_<%=SFCcart_Index+1%>" value="<%=WA_eCart_DisplayInfo(SFCcart, "Price")%>">
<input type="hidden" name="quantity_<%=SFCcart_Index+1%>" value="<%=WA_eCart_DisplayInfo(SFCcart, "Quantity")%>">
<% 'WA eCart Validation
SFCcart_Index = SFCcart_Index - 1
end if
set SFCcart = WA_eCart_MoveNext(SFCcart)
set SFCcart = WA_eCart_MoveFirst(SFCcart)
<input type="hidden" name="shipping_1" value="5">
<input type="hidden" name="shipping2_1" value="0">
<input type="hidden" name="currency_code" value="GBP">
<input name="CheckoutButton" type="image" value="Proceed to Checkout" src="stranraer-fc/btn-checkout.png" onmouseover="this.src='plugins/stranraer-fc/btn-checkouton.png'" onmouseout="this.src='plugins/stranraer-fc/btn-checkout.png'" alt="Proceed to secure checkout" border="0" />

We have a discount rule set up in our cart to deduct 10% from the sub-total amount, to give us a grand total, but we've noticed that this amount isn't being passed to PayPal. Instead, our form is simply passing the individual product prices to PayPal.

How do we pass the individual items to PayPal whilst, at the same time, passing the correct grand total amount (sub-total - discounts)?

Again, I've attached our view-basket.asp page and cart files.

Thank you.

Attached Files

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question





Ease of use


security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...