Search
Left Quote    Choose a job you love, and you will never have to work a day in your life.
- Confucius    
Right Quote
 
[login] | [Register]
 

Accept Coupon Codes for Downloads

by: sm0ke
Page: 3 of 3
(View All)

The download script

The verify file will redirect the user to a download script on your server so the file requested can be downloaded. We have the variables of $domain, $querystring and $redirectstr $domain is the location of your download.php script which is what we are about to look at, the domain must contain "?file=" at the end, the $redirectstr joins the domain and file variables together to give the full URL to which the user is directed.

download.php



And thats it - well, not quite. The script isnt secure, its not meant to protect highly private files / personal files from being downloaded but should give you an insight into accepting coupon codes, verifying that code and requested download against a database and allowing the user to download while deleting the coupon from being used again.

The download script here is one i downloaded from somewhere a good year or so ago, if i remember where or who wrote it ill post the credits later. - You can always secure this script and use a more secure download script to boot. but it should give the basics.

1  |  2  |  3  |  


No Comments for this page.

You Must be logged in or a member to comment.


Tutorial Stats

Tutorial Stats

6,784 Views
0 Total Comments
3 Rating of 5 (1 Votes)

Options

Tutorial Options

· Login to Rate This Article
· Login to Post a Comment
· Read more by this author
Digg This Article! Del.icio.us: Bookmark This Article Reddit: Bookmark This Article BlinkList: Blink This Article! YahooMyWeb BlogMarks: Add This Mark! Furl: Save This Article Spurl: Mark This Article

Articles

Related    

· Simple PHP Tutorial
· One File Website
· Pagination with PHP
· Building a Comments Script
· Complete Members System
· Variable Scope


Debt - Credit Card Consolidation - Internet Marketing - Bad Credit Loans

"AllSyntax.com" Copyright © 2002-2007; All rights lefted, all lefts righted.
Privacy Policy  |  Internet Rank