Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Coupon Code "accepted"

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 02-24-2009, 12:42 AM
 
Lee Lee is offline
 

Advanced Member
  
Join Date: Dec 2002
Posts: 95
 

Default Coupon Code "accepted"

Morning all,

Can anyone recommend any code to enable me to chnage the following on our site -

On Checkout we have a Coupon Code field, we run various Deals of the Day/Week, at the moment if a customer adds the code the page doesn;t inform them whether its been accepted or not, the Coupon Code just appears in the Confirmation of Order email.

modules/Discount_Coupons/add_coupon.tpl
is obviously the file I need to edit, but not sure how!!

I simply want to display a some text upon submission of the coupon code to say whether its been accepted or not.

Any advice??

Thanks in advance,
__________________
Lee

X-Cart 4.0.14 - heavily modified! (Linux)
www.lasertechgroup.com/uk
Reply With Quote
  #2  
Old 02-24-2009, 04:02 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Coupon Code "accepted"

It doesn't show in the order totals? That's the way X-Cart coupons work by default - they show as a line item in the sub-total with a red x next to it to remove it.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 02-24-2009, 04:24 AM
 
Lee Lee is offline
 

Advanced Member
  
Join Date: Dec 2002
Posts: 95
 

Default Re: Coupon Code "accepted"

Sorry, should have explained in a bit more detail.

We very very rarely use coupon codes to give money off an order, instead we promote free gifts when you spend over a certain amount on our own brand products. This could be ipods, digital cameras etc.

So for instance this week, spend over ё400 get an ipod shuffle, coupon code is LTIPOD.

Now this is setup in the coupon codes as "Free delivery" against an order totalling over ё400, this shows in the Confirmation of order email displaying the coupon code just under subtotal.

But I just want to place something when the original coupon code is submitted to say it has been entered, as we don;t use coupon codes to discount, the customer doesn;t see the code till they have completed the order so we get lots of customers entering it in the notes, i.e. "entered LTIPOD but nothing happened"

I just want to trigger something to say it has been entered.
__________________
Lee

X-Cart 4.0.14 - heavily modified! (Linux)
www.lasertechgroup.com/uk
Reply With Quote
  #4  
Old 10-06-2009, 08:18 AM
 
maineiac maineiac is offline
 

Member
  
Join Date: Jun 2005
Location: USA
Posts: 29
 

Default Re: Coupon Code "accepted"

Lee - I'm using 4.1.8 so I'm not sure if this will apply to your version or not.... But it's a quick fix for my customers to know that the coupon has been accepted.

1) Create a new language variable: txt_coupon_accepted
2) In skin1/modules/Discount_Coupons/discount_coupons.php find the following (around line 74):

# Add discount coupon
} elseif($my_coupon == 0) {
$cart["discount_coupon"] = $coupon;
}

and change it to:

# Add discount coupon
} elseif($my_coupon == 0) {
$cart["discount_coupon"] = $coupon;
$top_message['content'] = func_get_langvar_by_name("txt_coupon_accepted");
}

When a valid coupon is submitted, your txt_coupon_accepted text will appear in that ugly error/warning/information box in dialog_message.tpl.

Hope this helps someone...I just realized that the original post is 7 months old...but I was searching for this answer and perhaps someone else will be too!
__________________
maineiac

x-cart gold v4.0.18
x-cart gold v4.1.8
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 03:40 PM.

   

 
X-Cart forums © 2001-2020