01-12-2017, 08:27 PM
You're making sense. I just have to go back to some of my array logic and write some code or you can take a crack at it.
The gist of what I would do is for each checkbox that is checked, query the database for the id column WHERE color = red and then add that id to an array called $found (or something like that).
Then when you run your next query, only add the unique user id's to the array. (so you get an array of the user id of each user who was found once and only once).
Then you will do a foreach loop and query the users table for each user by id.
If you need help with the specific code, let me know and I can work something up.
The gist of what I would do is for each checkbox that is checked, query the database for the id column WHERE color = red and then add that id to an array called $found (or something like that).
Then when you run your next query, only add the unique user id's to the array. (so you get an array of the user id of each user who was found once and only once).
Then you will do a foreach loop and query the users table for each user by id.
If you need help with the specific code, let me know and I can work something up.