Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Discount coupon does not show up in the checkout process


peterOSC

Recommended Posts

HI; Friends,

I installed OSCommerce 2.3.1 recently and added the "dicount coupon" module yesterday, however, I do not see any coupon button or selection in any pages and all checkout processes, the final price does not include the coupon discount. I followed the installaton instruction and found that in "order.php" file line 327 ( this file is located in /OSCcommerce/includes/classes ), it is different from what on the instruction, below is what in the file

 

 

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

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

 

But in the instruction: it is

 

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

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

 

 

 

I am not sure if this difference gives the trouble.

 

 

Another difference is that in the instruction:

 

OPEN catalog/checkout_payment.php

FIND on line 269:

 

<h2><?php echo TABLE_HEADING_COMMENTS; ?></h2>

 

<div class="contentText">

<?php echo tep_draw_textarea_field('comments', 'soft', '60', '5', $comments); ?>

</div>

<?php

 

However, I do not see the last <?php at this position in my file, so does this cause the problem?

 

Any help will be highly appreciated.

 

Thanks.

 

Peter

Link to comment
Share on other sites

update for my post.

In the "Installation Instruction" , OPEN catalog/checkout_payment.php, FIND on line 269:

 

 

ADD this code after:

/* kgt - discount coupons */

if( MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS == 'true' ) {

?>

<h2><?php echo TABLE_HEADING_COUPON; ?></h2>

<div class="contentText">

</div>

<div class="contentText">

<?php echo ENTRY_DISCOUNT_COUPON.' '.tep_draw_input_field('coupon', '', 'size="32"', $coupon); ?>

</div> <?php } /* end kgt - discount coupons */

 

After I added this code, it complained about unexpected T-STRING '<'.

After extensive work, I changed the code as the following:

 

<?php

 

 

if( MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS == 'true' ) {

 

 

echo "<h2>".TABLE_HEADING_COUPON."</h2>";

echo "<div class=\"contentText\">"." </div>";

 

 

echo "<div class=\"contentText\">";

echo ENTRY_DISCOUNT_COUPON.tep_draw_input_field('coupon', '', 'size="32"', $coupon);

echo "</div>";

 

 

Then the coupon code input area shows up in the checkout. But, in the checkout summary, the coupon value is not displayed and the coupon value is not applied to the total.

 

I think I configured the Discount Coupon correctly and created the coupon correctly.

Any hint for trouble shooting will be very appreciated. This may be my last problem to solve before my website up to run.

This is really urgent help.

 

Thanks.

 

Peter

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...