Hi folks,
I have a situation where I'm about to do a batch-add of users to a database, and I don't have all of their vital stats. When they log in, I'm having the site do a query for their db records and if they're missing info (like fax number, company name, etc), I want the users to be sent to the "personal info" page, where they update their personal info.
I would just do a really kludgy "if $row[1] =='', send them to a the personal info page; if $row[2] == '', ..." check, but i just KNOW that there's an elegant way to do it to do with a foreach()/while()/eval() loop, that will allow for any number of database fields so that I can reuse the code someday.
Anyone have any ideas?
Thanks,
Inger
I have a situation where I'm about to do a batch-add of users to a database, and I don't have all of their vital stats. When they log in, I'm having the site do a query for their db records and if they're missing info (like fax number, company name, etc), I want the users to be sent to the "personal info" page, where they update their personal info.
I would just do a really kludgy "if $row[1] =='', send them to a the personal info page; if $row[2] == '', ..." check, but i just KNOW that there's an elegant way to do it to do with a foreach()/while()/eval() loop, that will allow for any number of database fields so that I can reuse the code someday.
Anyone have any ideas?
Thanks,
Inger