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

Discount on Quantity of an Item

Thread began 1/25/2011 12:43 pm by bjgarner241692 | Last modified 1/25/2011 5:03 pm by bjgarner241692 | 1568 views | 13 replies


If you insist:


if (isset(
$_GET["ID"])) {
$param_product = (get_magic_quotes_gpc()) ? $_GET["ID"] : addslashes($_GET["ID"]);
$query_product sprintf("SELECT Name,Description,Picture,Extra,prod_pricing.pricelevel,prod_pricing.price, prod_pricing.ID FROM life_prods INNER JOIN prod_pricing ON life_prods.Name = prod_pricing.ProdName WHERE %s = life_prods.ID ORDER BY prod_pricing.Price"GetSQLValueString($param_product"int"));
$product mysql_query($query_product$constring) or die(mysql_error());
$row_product mysql_fetch_assoc($product);
$totalRows_product mysql_num_rows($product);
// WA eCart AddToCart
if (isset($_POST["eCart1_1_ATC"]) || isset($_POST["eCart1_1_ATC_x"]))     {
$ATC_itemID $_POST["eCart1_1_ID_Add"];
$ATC_AddIfIn 0;
$ATC_RedirectAfter "cart.php";
$ATC_RedirectIfIn  "cart.php";
  if (isset(
$totalRows_product) && $totalRows_product 0)     {
$row_product WAEC_findRecordMySQL($product"ID"$ATC_itemID);
    if (
$row_product)     {
$ATC_itemName "".$row_product['Name']  ."";// column binding
$ATC_itemDescription "".$row_product['pricelevel']  ."";// column binding
$ATC_itemWeight floatval("0");// column binding
$ATC_itemQuantity "".$_POST["eCart1_1_Quantity_Add"]  ."";// column binding
$ATC_itemPrice floatval("".$row_product['price']  ."");// column binding
$row_product mysql_fetch_assoc($product);
$ATC_itemQuantity floatval($ATC_itemQuantity);
  if (
is_numeric($ATC_itemQuantity) && $ATC_itemQuantity != 0)     {
    if (
$ATC_RedirectAfter != "" && $eCart1->redirStr == "")     {
$eCart1->redirStr $ATC_RedirectAfter;
    if (isset(
$_SESSION['WAEC_ContinueRedirect'] = $_SERVER['PHP_SELF']."?".$_SERVER['QUERY_STRING'];
    else  {
$_SESSION['WAEC_ContinueRedirect'] = $_SERVER['PHP_SELF'];

<form name="eCart1_1_ATC_<?php echo $row_product["ID"]; ?>" method="POST"  action="<?php echo $_SERVER["PHP_SELF"]; ?><?php echo (isset($_SERVER["QUERY_STRING"]) && $_SERVER["QUERY_STRING"] != "")?"?".$_SERVER["QUERY_STRING"]:""?>">

                        <input type="hidden" name="eCart1_1_ID_Add" value="<?php echo $row_product["ID"]; ?>" />
                        <input type="text" name="eCart1_1_Quantity_Add" value="1" size="4" >
                        <input type="submit" class="eC_FormButton" value="Add to Cart" name="eCart1_1_ATC">

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