Jump to content


Photo

Selling electronic documents online


  • Please log in to reply
11 replies to this topic

#1 golebara

golebara
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 22 June 2006 - 06:09 AM

Hi guys,

I'm a newbie helping a client to create a website.

The client is selling workbooks online in a PDF document. I have already arranged with a bank for the online payment system. But I'm not sure where to start.

I need some sort of database where I can store the actual products (PDF files) and customer details, I guess.

Once the customer fills out his/her credit card details, it is then processed through the bank's payment system and it will return some code to say whether it is successful. If it is successful, then the PDF files will become available for download.

Any suggestions, advice will be greatly appreciated. Thank you.

Regards,

GB

#2 .josh

.josh
  • Staff Alumni
  • .josh
  • 14,871 posts

Posted 22 June 2006 - 06:56 AM

so... i just have to ask this, cuz i see this all the time: why did you take on a project if you don't know how to do it? Seriously, would you go around offering to fix people's cars or build their house for them, if you knew nothing about cars or building houses? Making a dynamic database driven website is not something you learn to do by just casually reading some book on a sunday afternoon, have it done before dinner.

if you know absolutely nothing about php, where to start is your first "hello world" program. And you are a long, long way away from getting to the level of where you need to be to do that project.

the way i see it, you have 2 choices:

a) tell your boss you got into something way over your head, please give it to someone else, don't fire me, etc..

b) go to freelancing and have someone do it for you.
Did I help you? Feeling generous? Buy me lunch! 
Please, take the time and do some research and find out how much it would have cost you to get your help from a decent paid-for source. A "roll-of-the-dice" freelancer will charge you $5-$15/hr. A decent entry level freelancer will charge you around $15-30/hr. A professional will charge you anywhere from $50-$100/hr. An agency will charge anywhere from $100-$250/hr. Think about all this when soliciting for help here. Think about how much money you are making from the work you are asking for help on. No, we do not expect you to pay for the help given here, but donating a few bucks is a fraction of the cost of what you would have paid, shows your appreciation, helps motivate people to keep offering help without the pricetag, and helps make this a higher quality free-help community :)

#3 shortj75

shortj75
  • Members
  • PipPipPip
  • Advanced Member
  • 118 posts
  • LocationPort Huron,mi

Posted 22 June 2006 - 07:45 AM

i apsolutley agee with crayon violent you got in way over you head php is a fairly simple codeing languagebut it takes a while to learn i have been coding in php/mysql for over a year and a half and i still dont know everything and for what you are asking to write it will take an really experienced coder at least a couple of days to write and get all the bugs out it may take longer unless they already have a script that resembles what you are looking for my suggestion to you is go through as many php tutorials that you can and and find some codes to download and fool around with them to learn php but it is gonna take a while and if you download someone elses code make sure it does not have a copywrite and if it does get the copywrite owners permission before you change it you can go to my site and download any script you want and change it i give everyone permission to do so there is a link to my downloads page in my signiture
The Short One

hopfully this helps if it doesn't sorry
i won't write the code for you!!! you don't learn that way

#4 AndyB

AndyB
  • Staff Alumni
  • Advanced Member
  • 5,465 posts
  • LocationToronto

Posted 22 June 2006 - 11:03 AM

[a href=\"http://www.payloadz.com\" target=\"_blank\"]http://www.payloadz.com[/a] - solves a huge number of your problems.
Legend has it that reading the manual never killed anyone.
My site

#5 golebara

golebara
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 22 June 2006 - 11:57 PM

Hi guys,

Thanks for the replies.

I am a C++ programmer and I have done some simple PHP coding before. The client is in fact a friend of mine and the reason why I took this work experience is because it is challenging and it keeps me busy for the holiday.

There aren't many courses you can take to practice setting up an online merchant website. So I want to have a go at it myself during my spare time and learn as I go (as most people do). I believe I have the skills to do the job but just don't know where to start exactly.

As far as this project goes, there isn't a deadline. I know it will take fully experienced programmers a couple of good days to code this and I have no intention to do so. I just have the desire to do something challenging and advance my skills further.

Thank you for your understanding.

Regards,

GB

#6 AndyB

AndyB
  • Staff Alumni
  • Advanced Member
  • 5,465 posts
  • LocationToronto

Posted 23 June 2006 - 12:08 AM

um, I gave you a complete solution that you could implement in minutes.

If you have lots of spare time and want to do something challenging and rewarding to keep you busy, why not volunteer your time to help a local charity?
Legend has it that reading the manual never killed anyone.
My site

#7 phpstuck

phpstuck
  • Members
  • PipPipPip
  • Advanced Member
  • 59 posts

Posted 23 June 2006 - 12:32 AM

MySQL will store all the customer details, I recommend storing the PDF files in a protected folder and calling them from a link stored in MySQL with PHP. I can appriciate your background and learning on the fly, that has lead to several disaters for me also. If you are a C++ programmer you should roll into advanced PHP rather easily. Set up your database and keep asking questions. You should be on the run in no time.There are actually built in mods for calling most of the resources you will need for payment processing once you have the site set up and can test the storage and download features.

For more on payment processing read the following tutorial right here on PHP Freaks
[a href=\"http://www.phpfreaks.com/tutorials/49/0.php\" target=\"_blank\"]payment processing with CURL[/a]



#8 legohead6

legohead6
  • Members
  • PipPipPip
  • Advanced Member
  • 434 posts

Posted 23 June 2006 - 05:15 AM

[!--quoteo(post=386746:date=Jun 22 2006, 01:09 AM:name=golebara)--][div class=\'quotetop\']QUOTE(golebara @ Jun 22 2006, 01:09 AM) View Post[/div][div class=\'quotemain\'][!--quotec--]
Hi guys,

I'm a newbie helping a client to create a website.

The client is selling workbooks online in a PDF document. I have already arranged with a bank for the online payment system. But I'm not sure where to start.

I need some sort of database where I can store the actual products (PDF files) and customer details, I guess.

Once the customer fills out his/her credit card details, it is then processed through the bank's payment system and it will return some code to say whether it is successful. If it is successful, then the PDF files will become available for download.

Any suggestions, advice will be greatly appreciated. Thank you.

Regards,

GB
[/quote]

I agree with everyone..this is one off the more complex php project out there(store, etc) i built one after afew months of nearly 6 hours a day php and it is still very rough!...... but i guess i learned in a rather simular way, only it was my own site i wanted to make!.....if your very beginner php go to w3schools.com opr else buy a book on php and mysql and start reading!
"Syntax error" .. WHERE THE **** IS IT?!

#9 golebara

golebara
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 23 June 2006 - 12:57 PM

Thanks phpstuck for the useful comments. I have already got some help through another friend and I just got a hosting that supports PHP/MySQL, CGI-BIN, Perl and etc.

I guess the next step is to design and implement the database and test it. After which, I will start doing the PHP coding.

Any suggestions about the design of the database? I will need a customers table to track customer records (name, address, phone, credit card details?, and etc). I guess I also need some sort of tracking system to track down customer orders (cookie perhaps?) as they are browsing through the website and ticking "Add to shopping cart" buttons. I was adviced by another friend to create a table to temporarily store orders using an unique ID (IP address perhaps). But I'm not sure how to do this exactly. Any help would be great.

P.S. To AndyB: I don't have the label "Superman" on my chest so I can't fly around and help everybody. Your complete solution is not gonna work with me. The payment system has already been setup through a bank and we don't want PayPal. I guess the secondary objective of doing this website is to advance my skills and of course by adapting a complete solution as so to speak would jeopardise the whole idea.

#10 Michael4172

Michael4172
  • Members
  • PipPipPip
  • Advanced Member
  • 41 posts

Posted 23 June 2006 - 03:39 PM

golebara,

A simple fix to this is to sign up for a hosted shopping cart. Once payment is processed through there, most have an option where a download link is sent to the user (you can set the link to expire XX mins/hrs after payment is received).

To me this would be your easiest solution.




#11 phpstuck

phpstuck
  • Members
  • PipPipPip
  • Advanced Member
  • 59 posts

Posted 23 June 2006 - 09:23 PM

First of all... DO NOT store credit card numbers, bad practice and you would have to be very good at security to do it, plus there is no need. Leave the credit cards to the payment processor.

I think many are missing the point of you using this as a chance to learn. I can assure you that you are about to write the mesiest code you have ever seen, and then you will throw it out and re-write it hundreds of times. But that is how everyone else learns too.

You are right, cookies and sessions will be the best way to track the shopping of your clients. There are several good tutorials online about writing your own php/MySQL shopping system that should help you get where you are headed. It won't be fast, but since you have a project in mind you will drive towards the goal. Your C++ background will certainly speed up the learning curve, since PHP is derived from C style syntax.

Good luck and just keep asking questions, someone will offer help, maybe not the Superman but some local superhero will emerge to help you with each trouble you run into.

For a quick start into many of the basics, run to Books a Million and get the book "PHP5 and MySQL BIBLE" Lots of good reading and helpful figuring out the basics and some more complex stuff.

Rob

#12 phpstuck

phpstuck
  • Members
  • PipPipPip
  • Advanced Member
  • 59 posts

Posted 26 June 2006 - 06:30 PM

Another great book on this subject...

Beginning PHP 5 and MySQL ECommerce: From Novice to Professional
by Cristian Darie and Mihai Bucica




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users