PDA

View Full Version : secure web pages



monkeyhead
February 22nd, 2007, 02:40 PM
is there a way to create a secure web page a browser cannot view by typing the url.

i want to be able to have a browser pay for a product from my site via paypal...afterwhich, paypal will direct them to a secure webpage for download.

the only thing is, i dont want that person to be able to give the link to his or her buddies and rip off my product.

thanks in advance,
Andre

evildrummer
February 22nd, 2007, 03:24 PM
You could use .htaccess, or a PHP page where a user has to type a password or have a special session/cookie.

bwh2
February 22nd, 2007, 03:33 PM
just create an account with a username and password.

s1ntax
February 22nd, 2007, 03:46 PM
just create a temp file.

when they go to download it, copy the original file into a folder youve created specially for temp folders (http://www.yoursite.com/downloads/temp/ would be approporiate) name the new temp folder after their session id, or something unique to them. then have a link on the page saying "you can download your file [here]" and provide the url for the temp download.

dont forget to set up a cron job to clean out your temps folder. once an hour should be approporiate. you should probably check the timestamp for the created file, estimate how long it would take to download on a 56k, add a few minutes for padding, and have your cron NOT delete files that have been created within that time.

vini
March 1st, 2007, 04:19 PM
create a .htaccess file in that folder.

Esherido
March 1st, 2007, 05:11 PM
With a .htaccess file, he could still give the username and password to his buddies. I think the idea s1ntax came up with is the best. Though it will take some coding. ;)