Forum Moderators: coopster
in the table there is:
id games.
I have tried many different codes but cant seem to find something that works. ANyone have any ideas? I am farely new to PHP and was able to pick up the first part of my form with no problem.
Thanks
Within your PHP application, maintain an array called $options, with elements corresponding to the users' settings; or in your case the games they have selected.
Then, in your database, have a single field called "options".
When the user has set options; write the output of serialize($options) into the options field in your DB. On retrieving a user record; use unserialize() [uk2.php.net] to recover the array from the DB.
This saves having hundreds of separate option field in your user table, and has the side benefit of reducing DB size considerably if you only populate values once they are set to TRUE.
For retrieving option values from a FORM, refer to this page on the PHP website:
[uk2.php.net...]