January 10th, 2013, 10:11 AM
have anyone ever done any programming .. that too web programming without a tutorial or copy pasting stuffs ?
i was thinking about something that says "not yet" before things get inserted into the table ..
isnt that how things usually are ...
i have to figure out the rest of the steps ....
January 10th, 2013, 11:03 AM
You need to spend some time with your nose in the php manual. My recommendation is study the php language, specifically the MySqlI extension. Study up on your MySql commands and syntax, and learn how to properly validate user input.
DO NOT COPY AND PASTE. This will lead to becoming an incompetent developer. Read tutorials and write your own code with what you learn from them.
Sorry we just dont have time to guide you through this entire project, especially with the number of free resources on the web. Just avoid w3schools at all cost and anything that uses mysql_ extension. Your just learning so learn the right way
January 10th, 2013, 11:04 PM
ok .. where else can i temperorily hold something ... other than in a table ?
January 10th, 2013, 11:54 PM
You can store data in many other places (cookies, sessions, text files). The question is: Why would you want that?
OK, before this thread becomes a back and forth over 10 pages:
You have members. A member has an email address, a password (not stored as plaintext!) and possibly a user name. That's the basic data. You also need to store the confirmation code as well as the confirmation status and the payment status. And you need basic personal info like the lastname, the firstname and the PayPal email address (to uniquely identify each payment). You'll probably also want to know the time of registration.
So your table layout will look something like this:
- password (a hash)
The password must not be stored as plaintext (like in your "tutorial"). Plain hashes like MD5, SHA-2 or whatnot are also not secure, because they're vulnerable to brute force attacks. Instead, use a password hashing library like PHPass.
The confirmation code must be truly random so that it cannot be guessed. Things like rand() or uniqid() do not generate strong random numbers. If your hoster has the OpenSSL library installed, use openssl_random_pseudo_bytes().
January 11th, 2013, 02:32 AM
thanks for that really detailed reply
The question is: Why would you want that?
basically i am trying to facilitiate login
January 11th, 2013, 09:56 PM
Everything other then session details and variables within the script itself at this point in your coding will be stored in tables. PLEASE at least make an attempt to use the all mighty GOOGLE/BING/YAHOO/UNCLE BOB! we are not here to write your code for you, nor teach you the ENTIRE language of PHP/MySQL.
Just next time you have a question just spend a good 15 minutes on bing. I bet you will find an answer, trust me! php is one of the most popular languages used in todays world and therefore there are thousands of good resources available online.
Im sorry but at this point if you don't "get" the idea of this simple system you should highly consider taking a class or researching general programming and logic. Then learn the syntax and command structure of PHP and the data structure of SQL.
With that said good luck!
Originally Posted by gether
January 12th, 2013, 12:53 AM
i am noob trying to understand the basics ...
this is what i am trying to do right now which involves
my admin having some sort of power to move things from the temperory table to the permenent table ...
January 12th, 2013, 01:04 AM
YOU DONT NEED TWO TABLES! like we said before use a Boolean value to specify which users are validated!!! This is all information outlined in detail in hundreds of tutorials and specified at least 5 times in this thread
Originally Posted by gether
Comments on this post
January 12th, 2013, 04:36 AM
gether, I gave you a complete layout of the members table with two status fields: "has_confirmed" and "has_paid".
If you still don't understand the concept, I don't see how we could possibly help you. This isn't even technics, this is common sense. 12 year old school kids do things like this in their spare time.
There's no problem with being a PHP newbie, but I don't see any effort or progress on your part. All you do is keep repeating "This is what I need to do: registration, login, bla bla bla". For god's sake, turn on your brains and start working, create the table in your phpmyadmin, play with it a bit in PHP, ask an intelligent question, anything. But don't just sit around and wait for us to spoonfeed you every tiny detail -- which you still don't get even after 5 different people have explained it 10 times.
Maybe this is just really, really too early. Maybe you should start with something simple like a guest book and move on from there.
If you want to do programming, you have to be able to think for yourself and work on your own. If you can't, this might not be the right thing for you.
Anyway, I'm out. Maybe I'll come back when you finally come up with a thought or result on your own (like a PHP snippet, a screenshot of your table in phpmyadmin, an intelligent question).
Don't wait for us to write this stuff for you. This is your project, not ours. Don't forget that.