Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
I had a question about encrypting a thank you page
Old 12-31-2008, 05:51 PM I had a question about encrypting a thank you page
Novice Talker

Posts: 5
Trades: 0
Hi, I'm trying to sell my ebook on the internet. And I looked into Paypal. Paypal allows you to direct a person to a Thank you page after they purchase my ebook.

So I made a link where they can download my ebook, but can someone teach me how I can encrypt the link, so they can only visit it and it will automatically close in 48 hours?

Thank you.
tsinvestments is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 12-31-2008, 06:01 PM Re: I had a question about encrypting a thank you page
Defies a Status

Posts: 1,606
Trades: 0
You will need some form of scripting to do that. You can encrypt the button and the return URL using the creation tools at PayPal. You can protect the page with some simple scripts but all can be broken in time.

Expiring links are much more complicated. For those you need some scripting and a database.

To start the encrpyted button, changing the file name a few days after each sale and making a new button are the free easy ways to do it.
__________________
Colbyt

Please login or register to view this content. Registration is FREE
colbyt is offline
Reply With Quote
View Public Profile
 
Old 12-31-2008, 06:11 PM Re: I had a question about encrypting a thank you page
Decaf's Avatar
Ultra Talker

Posts: 489
Name: Adam
Trades: 0
Quote:
Originally Posted by tsinvestments View Post
Hi, I'm trying to sell my ebook on the internet. And I looked into Paypal. Paypal allows you to direct a person to a Thank you page after they purchase my ebook.

So I made a link where they can download my ebook, but can someone teach me how I can encrypt the link, so they can only visit it and it will automatically close in 48 hours?

Thank you.
0) Gather payment from user
1) Create a unique id for the user
2) Hash the id and save it in a database
3) Direct the user to the page so they can get there eBook
3.5) Make the user submit a form/button/captcha that will send the id to a DB
3.75) Check there submitted and hashed Id against all the temp ones saved in the database.
3.8) Record there IP, email, date, time, book, id and store in a separate DB.
4) Give them there book if the hashed id's match and delete the ID so they can't reuse it
5) Direct them back to your home page/more of your books.

Step 3.8 is used for any legal action taken against you/your products, and to ensure that a human was involved in the process (captcha). That way if they claim to not have gotten there book or if they claim that "someone else" got it, you can provide the personal info to compare against/with them.

Wow, that numbering is wack, sorry. (P.S. this is NOT in any form all you need, if you really want it to be secure/legaly (correct grammer?) correct there are more steps to add.)
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE


Last edited by Decaf; 12-31-2008 at 06:15 PM..
Decaf is offline
Reply With Quote
View Public Profile Visit Decaf's homepage!
 
Old 12-31-2008, 06:17 PM Re: I had a question about encrypting a thank you page
Novice Talker

Posts: 5
Trades: 0
Decaf, would I have to pay you to try to get step by step instructions from you?
tsinvestments is offline
Reply With Quote
View Public Profile
 
Old 12-31-2008, 06:20 PM Re: I had a question about encrypting a thank you page
Decaf's Avatar
Ultra Talker

Posts: 489
Name: Adam
Trades: 0
Quote:
Originally Posted by tsinvestments View Post
Decaf, would I have to pay you to try to get step by step instructions from you?
Umm, I consider my self to suck at programming. But i would be more then happy to try to walk you through or a "real programmer" could assist.

What would you like to know more about? Or do you just want me to really detail it out?

Detailed:

1) Create a unique id for the user
1.1) Generate a random length (10-15 characters)

1.2) For each character, generate a random number (1-36) (a-z and 0-9)
1.3) If you really want to you can toss in extra conditions (Ex. 5th char must not be a d,o,e,7, or 3)

1.3.1) Or mix up the numbers (rand(1,$max) $key[rand] = $temp;$key[rand] = $key[rand2];$key[rand2] = $temp; )
2) "sha1($id)" the id and save it in a database

3) Direct the user to the page so they can get there eBook
3.1) Ex. "Click here to go to the download page"!

3.5) Make the user submit a form/button/captcha that will send the id to a DB
3.5.1) Ex. "Click this button to download $bookTitle" // More personalized.

3.75) Check there submitted and hashed Id against all the temp ones saved in the database.
3.75.1) foreach($storedID as $id) { if ($userID == $storedID[$n]) { setcookie("confirm",acceptDownload);header("Loatio n: DOWNLOAD PAGE");}

3.8) Record there IP, email, date, time, book, id and store in a separate DB. (On downlod page).
3.8.1) $_SERVER['REMOTE_ADDR'], $email, date(d/m/y); ect...

4) Give them there book if the hashed id's match and delete the ID so they can't reuse it<meta http-equiv="refresh" content="0;url=http://full/path/to/books" />
5) Direct them back to your home page/more of your books.
"Click here to go to our home page, $name".

Something like that, or use a Shopping Cart Software to save coding.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE


Last edited by Decaf; 12-31-2008 at 06:35 PM..
Decaf is offline
Reply With Quote
View Public Profile Visit Decaf's homepage!
 
Old 12-31-2008, 06:33 PM Re: I had a question about encrypting a thank you page
Novice Talker

Posts: 5
Trades: 0
Well pretty much i know how to get into my wampserver, and know how to follow directions, but I don't know how to program. I can click buttons, and copy and paste. I can get into the mysql page but that's about it. I might need your help.

Are you charging for this? Seems like you have your own web design/development company http://www.decafproductions.com right?
tsinvestments is offline
Reply With Quote
View Public Profile
 
Old 12-31-2008, 07:06 PM Re: I had a question about encrypting a thank you page
Decaf's Avatar
Ultra Talker

Posts: 489
Name: Adam
Trades: 0
Quote:
Originally Posted by tsinvestments View Post
Well pretty much i know how to get into my wampserver, and know how to follow directions, but I don't know how to program. I can click buttons, and copy and paste. I can get into the mysql page but that's about it. I might need your help.

Are you charging for this? Seems like you have your own web design/development company http://www.decafproductions.com right?
No, i strongly think that "almost" everything should be open source. Those prices and that site need to be updated (after newyeas?). If you are not a programmer then i suggest a free shopping cart software: http://google.com/search?q=free+shopping+cart+software

I will work on a script because I'm self-debating if i can do this or not.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE


Last edited by Decaf; 12-31-2008 at 07:33 PM..
Decaf is offline
Reply With Quote
View Public Profile Visit Decaf's homepage!
 
Old 12-31-2008, 09:05 PM Re: I had a question about encrypting a thank you page
Novice Talker

Posts: 5
Trades: 0
I have a host called 1and1 but I personally believe that its making me make a page with their own code. I can't really manipulate the code. It is making me upload, drag and drop, browse type website.
tsinvestments is offline
Reply With Quote
View Public Profile
 
Old 12-31-2008, 09:06 PM Re: I had a question about encrypting a thank you page
Novice Talker

Posts: 5
Trades: 0
Thanks for your help sir.
tsinvestments is offline
Reply With Quote
View Public Profile
 
Old 01-01-2009, 10:28 AM Re: I had a question about encrypting a thank you page
Decaf's Avatar
Ultra Talker

Posts: 489
Name: Adam
Trades: 0
Quote:
Originally Posted by tsinvestments View Post
I have a host called 1and1 but I personally believe that its making me make a page with their own code. I can't really manipulate the code. It is making me upload, drag and drop, browse type website.
hmm, I have the same host and they are great, I threatened them with leaving because they had me on PHP 4.4.9. 15 minutes later i got a response that actually worked. During the weekday to!
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Decaf is offline
Reply With Quote
View Public Profile Visit Decaf's homepage!
 
Reply     « Reply to I had a question about encrypting a thank you page
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 1.16598 seconds with 12 queries