Magento Forum

Coupon codes in urls
 
mstanchi
Jr. Member
 
Total Posts:  12
Joined:  2008-10-09
 

Hello, I have the discount code box in my shopping cart and have price rules set up for various coupon codes.  It works great.

But now I want to create a URL to embed in banner ads/ecards that when clicked it will take them to my site will automatically apply a discount code.  By the way, the link will take them to the main page (ie mydomain.com) but they won’t need the coupon until checkout (ie mydomain.com/index.php/checkout/cart/)

Is this possible?

thanks, Matt

 
Magento Community Magento Community
Magento Community
Magento Community
 
nico5
Sr. Member
 
Avatar
Total Posts:  214
Joined:  2008-02-19
France
 

You have to write some PHP code to do that.

 
Magento Community Magento Community
Magento Community
Magento Community
 
mstanchi
Jr. Member
 
Total Posts:  12
Joined:  2008-10-09
 

Thanks for pointing me in the right direction.  Any sugguestion (ie snipets, examples, tutorial) on how to do this with PHP?

 
Magento Community Magento Community
Magento Community
Magento Community
 
nico5
Sr. Member
 
Avatar
Total Posts:  214
Joined:  2008-02-19
France
 

You have (for example) to create a new module that adds the coupon code at the checkout

 
Magento Community Magento Community
Magento Community
Magento Community
 
ScotJ
Jr. Member
 
Total Posts:  3
Joined:  2008-12-29
 

Would it be further possible to automatically have someone join a customer group (even if not registered) by defining a set variable in the landing URL?  And then associating certain discounts or coupon codes for that customer group?

 
Magento Community Magento Community
Magento Community
Magento Community
 
clinch
Jr. Member
 
Total Posts:  10
Joined:  2009-09-04
 

I’m also wondering if there is a module for this yet. Has anyone done this successfully?

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top