Can this be done?

Status
Not open for further replies.

rex_b

Uber Rex
Jun 26, 2006
130
1
0
Louisiana
Let's say I have a coupon on a page that people can print to bring into a store for discounts.

And let's say I want people to be able to print that page x number of times for friends. But on that page there is a random number that needs to be generated everytime so therefore the page needs to be reloaded each time before each print.

Can this be done with 1 simple click of a button?
 


Well, basically you want a person to be only able to print one copy per visit to the page? What's to stop them from going Print->Copies = 10

I mean just changing the number of copies on the print menu to more than one?

Am i understanding you correctly?
 
Well I want a person to print a page how ever many times they input into a box on the page. But it must print that page with different random numbers generated on that page each time.
 
Is this going to generate a new barcode each time?

If not, there really is no reason they can't just click File->Print in their browser and print off whatever quantity they want.
 
Each page has to have a different number. So when they put 5 in the input box and click the print button on the page it needs to print 5 pages, each with a different random number.

I don't want them to have to go to file click print then reload then go to file then print. etc. etc.
 
I guess I am just having a hard time understanding how the random number fits into all this. You want to keep people from using bots? How are the coupons going to be distinguishable from each other?

If every coupon is going to be exactly the same, there is no reason they can't just put 1 in the box and then go to the coupon and print off 50 by using the method I said or just take it to a copier.
 
Each coupon needs a Member ID number which is randomly generated.

Thus each page needs a different number.

Thus they would have to reload and go to file>print way too many times. I just want them to enter 5 into a box and the script does it for you.
 
just set it to have 1 print run of 5 different pages, not 5 print runs. IE the pages are created with the different usernumbers at the time of the print.

That wouldnt stop someone printing 5 copies (so would have 25 coupons). Not sure how you stop that.
 
I'm not sure if it's possible but if it is, it would need some sort of javascript that handles 5 print initialisations.
 
You can't do it the way you're asking. Have the user input the number of pages (cupons) they wish to print, then generage a X number of page pdf file on the server side, each page with a different number on it. It'll take some backend coding, but that's how I'd do it. I try to use .pdf for anything that I intend on the user printing.
 
Status
Not open for further replies.