close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Is there an eCart Discount variable available?

Thread began 3/22/2010 5:34 pm by steve283594 | Last modified 3/25/2010 4:57 pm by steve283594 | 2004 views | 7 replies

Eric Mittman

You might be able to get at the info that you need for the discount by making use of the rule looper function. Here is an example of what this function looks like in action, I took this from my cart display:

<%
if (NOT WA_eCart_Rules_EOF(eCart1, "Discounts")) then
while (NOT WA_eCart_Rules_EOF(eCart1, "Discounts"))
if (WA_eCart_RuleLooperValue(eCart1, "Discounts") > 0) then
%>
<tr>
<td class="eC_IndividualCharge"><%=WA_eCart_RuleLooperName(eCart1, "Discounts")%></td>
<td>-<%=WA_eCart_DisplayMoney(eCart1, WA_eCart_RuleLooperValue(eCart1, "Discounts"))%></td>
</tr>
<%
end if
set eCart1 = WA_eCart_Rules_MoveNext(eCart1, "Discounts")
wend
set eCart1 = WA_eCart_Rules_MoveFirst(eCart1, "Discounts")
end if
%>



In this code once you looping over the rule you can get it's name and value like this:

name:

<%=WA_eCart_RuleLooperName(eCart1, "Discounts")%>



value:

WA_eCart_RuleLooperValue(eCart1, "Discounts")

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

Content

rating

Layout

rating

Ease of use

rating

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...