I gang

PHP Single-Use Coupon Generator and Validator

We have a MySQL database with a table called "keys". It contains "ID" and "Key." We already have php code that will verify (and optionally delete too) entries (a.k.a. coupon codes) in that table. We also have php code that will write random coupon codes into the table. However, WHAT WE NEED is php code that gives a user the ability to create a sequential number range of numeric coupon codes, and for that range to be configurable through a web form.

A screenshot of the database table is attached (We manually entered in sequentially numbered entries to demonstrate what the final product needs to do).

We would like for our client to be able to create a numeric range of coupon codes from, for example, 1000001 to 2000000 (or whatever number range they choose). Here is a crude diagram of the web form:


Create Coupon Codes

Number Range Minimum: [TEXT BOX]

Number Range Maximum: [TEXT BOX]



Next, we will need the ability to take one of those coupon codes (with the option of only using each coupon code once), and do something with it. For right now, we would like a public web form that asks for the visitor's name and email address, and upon successful submission and/or redirection to a new page, it then emails a coupon code to the address entered into the form. It also should post the form data info another table in our database. We also need to prevent the same email address from getting more than 1 coupon.

For example...


Enter your email address and we will

send you a coupon code.

Email Address: [TEXT BOX]



Once we have those things in place, we'll have the ability to help our clients in the following scenario:

Restaurant general manager, Chris, would like to do an online customer survey to gather feedback from customers. The survey is very long, so he needs to give away a pretty substantial incentive to get people to fill out the survey. He's decided to give away a coupon for two free draft beers to those who complete the survey. You complete the

survey, and the system emails you a coupon. Of course this all needs to be automated, but the problem with most automated responses is that they are limited to static content, meaning everyone that completed the

survey would get the exact same email. The coupon would be the same for everyone, and Chris would have no way of telling if the coupon was redeemed more than once. This is not that big of a deal for small coupons like 10% off, but for coupons such as Two Free Drafts, it's a problem and will be abused. Chris needs the ability to make "single use" coupon codes and automate their delivery...

Chris needs to:

1. Specify a custom range of coupon code numbers, and post every number in that range to the "keys" table in his database.

2. Give his guests a web form, and if they submit the form successfully, they will get an automated email with one of the coupon codes generated in step one (a random one from within that range). Once that coupon code has been emailed to someone, it will not be emailed to anyone else.

3. Have a web form on his end where he can enter a customer's redeemed coupon code to validate it. One the code has been used once, it will no longer be valid (deleted from the database).

We already have the php code for number three on that list. We just need code for the ability to perform steps one and two.

here is the referred to php code hosted (also attached)...

[url removed, login to view]


[url removed, login to view]

We do NOT want any design work or extensive css styling added. Keep it as basic as possible, and we will add the design.

You are welcome to not use the attached code if it will be faster for you (and less expensive for us) to complete this project. We only purchased this code to lower the overall cost of the project, but if that is not the case, we have no other reasons to keep the code and it can be discarded.

Evner: MySQL, PHP

Se mere: php coupon generator, coupon generator php, coupon php mysql, php coupon code generator, single use coupon generator, coupon code generator php, single use coupons, single use coupon codes generator, coupon mysql table, coupon mysql php, coupon code php mysql single, single use code php, numbered coupon generator, coupon table php, coupon code generator php mysql, online free coupon codes generator validator, single use coupon, coupons code generator php, php mysql coupon code generator, php generator mysql coupon, php coupon code validate, single use code generator, generator coupon codes php, free single use coupon code generator online, what php can do

Om arbejdsgiveren:
( 2 bedømmelser ) Tampa, United States

Projekt ID: #984845

Tildelt til:


I can easily do this and very quickly.

$104 USD in 4 dage
(0 bedømmelser)

12 freelancere byder i gennemsnit $119 på dette job


pls chk pmb

$230 USD in 4 dage
(521 bedømmelser)

Thank you for the detailed explanation. All understood well. I can create exactly what you're looking for. Please contact me as soon as possible.

$100 USD på 1 dag
(58 bedømmelser)

soonest possible

$100 USD på 1 dag
(78 bedømmelser)

Hi, please check pmb for more details

$95 USD på 1 dag
(13 bedømmelser)

Hi, please check PM

$103 USD in 14 dage
(11 bedømmelser)

please check pmb

$100 USD in 7 dage
(4 bedømmelser)

Please see PM

$150 USD in 20 dage
(3 bedømmelser)

I am very interested your project! Please check PMB for details! Thank you very much!

$80 USD på 1 dag
(2 bedømmelser)

i will provide you best quality work. please check PMB.

$100 USD in 3 dage
(0 bedømmelser)

Hello!! Check your inbox.

$100 USD in 2 dage
(0 bedømmelser)

Hey there, I'm also from the USA. Please check the Private Message I sent you. Thanks.

$215 USD in 3 dage
(0 bedømmelser)

we provide only authentic work..

$50 USD in 15 dage
(0 bedømmelser)

I can do it! I can help you, sir!

$80 USD in 10 dage
(0 bedømmelser)