Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

xhowiexo

Archived
  • Posts

    1
  • Joined

  • Last visited

Posts posted by xhowiexo

  1. hello KGT,

     

    thx for this nice contribution. I have installed the latest release. It seems to work, but there is some broblem anyway:

     

    1. Installation catalog/includes/classes/order.php

     

    My code is alittle different from those you let us change to:

     

            //kgt - discount coupons
           if( is_object( $this->coupon ) ) {
             $applied_discount = 0;
             $discount = $this->coupon->calculate_discount( $this->products[$index], $valid_products_count );
             if( $discount['applied_discount'] > 0 ) $valid_products_count++;
             $shown_price = $this->coupon->calculate_shown_price( $discount, $this->products[$index] );
             $this->info['subtotal'] += $shown_price['shown_price'];
             $shown_price = $shown_price['actual_shown_price'];
           } else {
             $shown_price = tep_add_tax($this->products[$index]['final_price'], $this->products[$index]['tax']) * $this->products[$index]['qty'];
             $this->info['subtotal'] += $shown_price;
           }
           /**************
           $shown_price = tep_add_tax($this->products[$index]['final_price'], $this->products[$index]['tax']) * $this->products[$index]['qty'];
           $this->info['subtotal'] += $shown_price;
           **************/
           //end kgt - discount coupons

     

     

    but my original file is this:

     

    /**************

    $shown_price = $currencies->calculate_price($this->products[$index]['final_price'], $this->products[$index]['tax'], $this->products[$index]['qty']);

    $this->info['subtotal'] += $shown_price;

    **************/

     

    2. installation admin/includes/boxes/catalog.php

    and

    installation admin/includes/boxes/reports.php

     

    Your code to change is:

     

    //kgt - discount coupons
                                      '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a><br>'
                                      '<a href="' . tep_href_link(FILENAME_DISCOUNT_COUPONS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_DISCOUNT_COUPONS . '</a>' );
                                      /***************
                                      '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' );
                                      ***************/
                                      //end kgt - discount coupons 

     

    but I think there is a dot missing after the 2nd line (because with dot its working)

     

                                       //kgt - discount coupons
                                      '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a><br>' .
                                      '<a href="' . tep_href_link(FILENAME_DISCOUNT_COUPONS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_DISCOUNT_COUPONS . '</a>' );
                                      /***************
                                      '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' );
                                      ***************/
                                      //end kgt - discount coupons 

     

    3. After proceed from checkout_payment to checkout_confirmation I get displayed this code above my website (above the header):

     

    case 'fixed': $discount_amount = $currencies->format( $this->coupon['coupons_discount_amount'] ); break; } $min_order = ( $this->coupon['coupons_min_order'] != 0 ? ( $this->coupon['coupons_min_order_type'] == 'price' ? $currencies->format( $this->coupon['coupons_min_order'] ) : (int)$this->coupon['coupons_min_order'] ) : '' ); //replace the variables with their proper values: $display = str_replace( '[code]', $this->coupon['coupons_id'], $display ); $display = str_replace( '[discount_amount]', $discount_amount, $display ); $display = str_replace( '[coupon_desc]', $this->coupon['coupons_description'], $display ); $display = str_replace( '[min_order]', $min_order, $display ); $display = str_replace( '[number_available]', $this->coupon['coupons_number_available'], $display ); $display = str_replace( '[tax_desc]', $tax_group, $display ); return $display; } function is_errors() { if( count( $this->messages['error'] ) > 0 ) return true; return false; } function message( $message, $error_level = 'error' ) { $this->messages[$error_level][] = $message; } function get_messages( $error_level = 'error' ) { if( $error_level == 'debug' ) return $this->messages; return $this->messages[$error_level]; } } ?> 

     

    Any ideas and support? Thx in advance.

     

    Btw, my website is www.lifestyle1001.com

×
×
  • Create New...