wrigley Posted December 12, 2008 Share Posted December 12, 2008 What I'm trying to achieve is a check-in system for my church youth group. I have 2 tables (can create more if needed) in the database one for students and one for dates. I would like to make a list of the students all with a checkbox next to their names and be able to go down the list and select the students that are there. Then when done we can click the Submit button and it would add it to the table along with the date. I would then like to be able to view the information back and be able to edit later if needed. Please let me know if this is possible and if so what the easiest way of doing so is. Thank You in advance, Nathan Brown Link to comment https://forums.phpfreaks.com/topic/136608-is-this-possible-with-just-php/ Share on other sites More sharing options...
phpSensei Posted December 12, 2008 Share Posted December 12, 2008 110% possible. First I would get started on those mysql tables. Link to comment https://forums.phpfreaks.com/topic/136608-is-this-possible-with-just-php/#findComment-713321 Share on other sites More sharing options...
wrigley Posted December 12, 2008 Author Share Posted December 12, 2008 Ok, glad to hear it. I created the following table for the students. CREATE TABLE `extremec_churchadmin`.`adm_impact_students` ( `student_id` MEDIUMINT( 11 ) NOT NULL AUTO_INCREMENT PRIMARY KEY , `fistname` VARCHAR( 255 ) NOT NULL , `lastname` VARCHAR( 255 ) NOT NULL , `bday_day` VARCHAR( 255 ) NOT NULL , `bday_month` VARCHAR( 255 ) NOT NULL , `bday_year` VARCHAR( 255 ) NOT NULL , `address1` VARCHAR( 255 ) NOT NULL , `address2` VARCHAR( 255 ) NOT NULL , `city` VARCHAR( 255 ) NOT NULL , `state` VARCHAR( 255 ) NOT NULL , `zip` VARCHAR( 255 ) NOT NULL , `phone` VARCHAR( 255 ) NOT NULL , `grade` VARCHAR( 255 ) NOT NULL , `group` VARCHAR( 255 ) NOT NULL ) ENGINE = MYISAM and I created the following table for the dates (which I don't know if this is correct for what I need). CREATE TABLE `extremec_churchadmin`.`adm_impact_dates` ( `date_id` MEDIUMINT( 11 ) NOT NULL AUTO_INCREMENT PRIMARY KEY , `date` VARCHAR( 255 ) NOT NULL ) ENGINE = MYISAM Do you have a IM service you use so you can maybe help me alittle more? Thanks, Nathan Brown Link to comment https://forums.phpfreaks.com/topic/136608-is-this-possible-with-just-php/#findComment-713357 Share on other sites More sharing options...
xtopolis Posted December 12, 2008 Share Posted December 12, 2008 You should keep this on the forum to improve your potential quality and quantity of responses. Your tables are a good start, but some columns are redundant, and some columns use reserved words. First table: bday_day.. month year.. could just be a birthday (type: DATE) column city , perhaps varchar 255.. a little overdoing it state, if this is in the united states, you won't need 255 spaces for 2 Letter abbreviations. (use CHAR(2) I think phone ~arguable, could store it as int, and also be 10 digits grade ~again most likely going to be a number no larger than 2 digits group ~ should be an int as well, pointing to a groupid in another table second table: date ~ is a reserved word, perhaps: eventdate would be better Other: if you're going to have groups, make a group table, with groupid, groupname, and have the adm_i... students group column reference their groupid(s?) Questions you should ask yourself: -Can a student belong to more than one event? -Can a student belong to more than one group? -A table / way of showing students checked in for ___ event Link to comment https://forums.phpfreaks.com/topic/136608-is-this-possible-with-just-php/#findComment-713367 Share on other sites More sharing options...
wrigley Posted December 13, 2008 Author Share Posted December 13, 2008 Ok, I will make the changes to the tables, thank you very much for the tips. Im not able to modify them as of this moment because of some server maintenance issues. I did plan on have the groups come from another group table and be referenced by the group id. I'll try to get the table updated within the next day or so. Again, Thank you very much for your time and help. Link to comment https://forums.phpfreaks.com/topic/136608-is-this-possible-with-just-php/#findComment-714413 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.