PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Coupon Code field for Mass Coupon Code List

  1. matsilva
    Member

    Has anyone found a way to incorporate using a mass coupon code list into a Gravity Forms field but applying the amount or percentage of the discount to the PayPal Pro Add-on so the calculations are correct in the pricing?

    I understand there is a add-on available here https://github.com/curtismchale/Coupons-for-Gravity-Forms however this is entry by entry and doesn't allow for a long list from Groupon or another services where you get hundreds at a time.

    Anyone have any luck with this?

    Posted 12 years ago on Tuesday October 30, 2012 | Permalink
  2. matsilva
    Member

    I thought I read something about a list from a text file that could be used but I can't find anything on the forums here for it.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  3. How is your form being used that you need to enter a list of coupons?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  4. matsilva
    Member

    Basically you need to enter the coupon code to receive the discount amount while on the form.

    So an entry field would suffice, I just need to be able to use a long list with the value attached to it for a specific item or product.

    Or even just the value of the discount applying would be ok.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  5. So the visitor will enter one coupon code? And you need to validate that coupon code against a list of all valid coupon codes? Which part does not work right now?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  6. With Curtis' plugin, the coupon codes are stored as custom posts I believe. So, are you looking for a a way to create a bunch of posts quickly, one for each coupon code?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  7. matsilva
    Member

    Correct the visitor will enter 1 code but it needs to validate against the list unique codes and then remove or invalidate it as it would be a 1 time usage.

    The plugin via Curtis seems to be cumbersome to have to sift through over a thousand coupon codes to turn off a specific one once used. I would think using custom posts in the database would bog it down as well.

    I thought I ready a post from David Peralty here about having a text file for this matter.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  8. I wrote a function a while back to check a code entered against a text file of all valid codes. It did not include any coupon or discount functionality though. I'm sure you could add it.

    See if this is a step in the right direction:
    http://www.gravityhelp.com/forums/topic/database-look-up-validation#post-43732

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  9. matsilva
    Member

    Thanks Chris, nice function.

    I think that may be the ticket. I will try it out.

    Could that be duplicated for multiple files?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  10. Yes. That was a specific application, unlike David Smith's functions which are meant to be applied more generically. We can check multiple files if you need to. I can't see the use case for it but I'm sure you have a good reason for it.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  11. matsilva
    Member

    It would be due to having multiple promotions via Groupon, LivingSocial, Google Offers and AmazonLocal. Since these all have unique codes that are unique to each service I think intermingling them wouldn't work so well.

    Is there a function to apply a discount based on the codes entered? I think I would need to add values to the text file and the function to apply to the PayPal Pro add-on correct?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  12. I thought it might be related to different lists of coupons. You can do that. Maybe in your form you would have a radio button selection for the type of coupon they are going to enter, then you just check that one file, or maybe the codes follow a specific enough format that you can tell from the code which deal site it came from. So, yes, it can be done.

    A discount based on the code. I'm not yet sure how that would work. I think I would look at how Curtis did it in his add-on and try and get some ideas from there.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  13. matsilva
    Member

    Hi Chris,

    I am hacking away at this but noticed that if I don't add a value to the field for your snippet and attempt to move forward in the next step of a multi-step form that field will not let me continue as if it was a "required" field. However it isn't get to required.

    Anyway to edit the snippet to fix this?

    Posted 12 years ago on Thursday November 1, 2012 | Permalink
  14. I'm not sure I follow you. Can you post a link to the form online and let us know where the hangup is?

    Posted 12 years ago on Wednesday November 7, 2012 | Permalink
  15. If this is a duplicate of this post:

    http://www.gravityhelp.com/forums/topic/ensuring-a-field-is-saved-to-next-page-of-multi-page-form

    or is otherwise unnecessary, please let us know here and we will close this topic.

    Posted 12 years ago on Wednesday November 7, 2012 | Permalink
  16. matsilva
    Member

    Basically the snippet you provided was great but it wouldn't let me proceed through a multi-step form without putting a coupon value in the field. However it wasn't set to be "required". I took it off the form so that it could work properly.

    This is different from the other post because your snippet isn't the same as the plugin from the guy that developed it.

    Just trying to find a simple solution for mass coupon codes that actually create the discount and work with a multi-step form and work.. I can't seem to find any solution with all of that combined.

    Posted 12 years ago on Wednesday November 7, 2012 | Permalink
  17. I think your best bet is to work with Curtis McHale and making his coupon functionality work for you. The snippet I provided just checked to be sure a code was valid.

    Posted 11 years ago on Monday November 12, 2012 | Permalink
  18. matsilva
    Member

    Yeah the developer isn't very responsive to that it seems. We'll have to come up with something more supported because this is a feature many other popular form solutions have like wufoo and so on that would be very useful.

    Posted 11 years ago on Monday November 12, 2012 | Permalink