close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Updating prices without cart plugin

Thread began 5/09/2011 6:26 am by lee.m425923 | Last modified 6/21/2011 12:12 pm by Jason Byrnes | 998 views | 5 replies |

lee.m425923

Updating prices without cart plugin

Hello

I have a problem. My predessor used WA_Ecart to build a shop. He has now left the company and does not seem to have left the Dreamweaver plugin here. I need to increase some product prices in the cart, but am unable to find how they are generated.

Can anybody offer any assistance?

Many thanks

Lee

Sign in to reply to this post

Jason ByrnesWebAssist

in the page code, there will be a line similar to:

php:
$ATC_itemPrice = floatval("10");// column binding



this sets the price to $10.00


you can edit this price directly in the code.

Sign in to reply to this post

lee.m425923

Many thanks, you're a life saver.

Lee

Sign in to reply to this post

Jason ByrnesWebAssist

No Worries.

Sign in to reply to this post

lee.m425923

Discounts

Hello

I am having difficulties with this again. I found some code in Xcart_PHP.php which I assume sets a discount coupon code.

function WAEC_Xcart_PromotionalDiscount()  {
$totalDiscount = 0;
if (true && ((sizeof($this->Items) > 0) && ((isset($_SESSION['PromoCode'])?$_SESSION['PromoCode']:"") == "PGMAY10"))) {
$totalDiscount += ($this->TotalColumn("TotalPrice") * 0.10);//Result
}
return WA_eCart_FormatNumber($totalDiscount, $this->ForceDecimalsC, $this->DecimalPlacesC);



This suggests a code has been created before and it discounts 10%. I need a flat discount of £4.95. How can I do this?

Many Thanks

Sign in to reply to this post

Jason ByrnesWebAssist

yes, that code sets a discount coupon.

if you want to replace the coupon with a flat discount, change that to:

php:
function WAEC_Xcart_PromotionalDiscount()  {

  $totalDiscount = 0;
  if (true && ((sizeof($this->Items) > 0))) {
    $totalDiscount += 4.95;//Result
  }
  return WA_eCart_FormatNumber($totalDiscount, $this->ForceDecimalsC, $this->DecimalPlacesC);
}




if you want to add a new discount rule, you will need to purchase eCart, we do not offer support for hand editing the ecart object.

Sign in to reply to this post

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