Search found 3 matches

by TheArmedFarmer
Tue Dec 23, 2008 12:52 pm
Forum: Technical Tips, Questions & Discussions (Computers & Internet)
Topic: Registration program/module in php?
Replies: 14
Views: 3211

Re: Registration program/module in php?

Take up someone on their generous offer to help. You have done so much for firearm owners in Texas, it's time to sit back and receive a little help in return. There are probably half a dozen people who would be very happy to set you up with what you want, and it would likely only take an hour or so.
by TheArmedFarmer
Fri Dec 19, 2008 9:32 am
Forum: Technical Tips, Questions & Discussions (Computers & Internet)
Topic: Registration program/module in php?
Replies: 14
Views: 3211

Re: Registration program/module in php?

Charles L. Cotton wrote:Thanks! Now tell me the truth. How long were you laughing? :lol:
Not even for a minute. I'm actually impressed by your ambition to learn PHP. A simple registration form will be an excellent learning experience for you.
by TheArmedFarmer
Thu Dec 18, 2008 5:31 pm
Forum: Technical Tips, Questions & Discussions (Computers & Internet)
Topic: Registration program/module in php?
Replies: 14
Views: 3211

Re: Registration program/module in php?

Step 1: Create your table with an auto-increment primary key.

Code: Select all

CREATE TABLE `registrations` (
  `name` varchar(200) NOT NULL default '',
  `phone` varchar(200) NOT NULL default '',
  `etc` varchar(200) NOT NULL default '',
  PRIMARY KEY  (`rid`)
) ENGINE=MyISAM AUTO_INCREMENT=0 DEFAULT CHARSET=latin1;
Step 2: Insert into the database table the results from the registration form you setup.

Code: Select all

INSERT into registrations (name, address, etc) values ('$name','$address','$etc);
Step 3: Get the new unique ID from the insert you just made.

Code: Select all

SELECT LAST_INSERT_ID();
Step 4: That ID will be the confirmation number for the person to print.

Step 5: Find out how many rows (registrations) you have.

Code: Select all

SELECT COUNT(*) FROM registration
Step 6: If results of step 5 are the number that you want, then print a message saying registration is closed.

Easy peasy. :-)

Return to “Registration program/module in php?”