Page 1 of 1
how to update in checkboxes??
Posted: Thu Jan 18, 2007 8:36 pm
by PHPycho
i have listout the designation of user in checkbox with auto checked in respective field.
i have table named
and
Code: Select all
users_designation(id,user_id,designation..)
While in edit section, i am feeling a bit difficulty in editing..
i am thinking to delete all the previous values in users_designation table and
to insert the freshly checked ones..i am doing right or there is an alternative way..
i am awaiting for your help.
Thanks in advance to all of you..
Posted: Fri Jan 19, 2007 9:13 am
by Kieran Huggins
I'm a bit confused about what you're doing...
If it's what I think you're doing, why not just use the primary key of the users table?
Posted: Fri Jan 19, 2007 4:27 pm
by PHPycho
users is the table name and the things in the () are fields and same case for users_designation.
I dont know in what you are confused.
Posted: Fri Jan 19, 2007 4:36 pm
by aaronhall
PHPycho wrote:users is the table name and the things in the () are fields and same case for users_designation.
I dont know in what you are confused.
The description of your problem is ambiguous. What exactly is it that you are doing? What is stored in users_designation?
PHPycho wrote:i have listout the designation of user in checkbox with auto checked in respective field
What does that mean?
Posted: Fri Jan 19, 2007 6:55 pm
by PHPycho
sorry if i am not clear.
i will try once again..
i have two tables name users and users_designation
-users table has fields like id,username,password....etc
-users_designation table has fields like id,user_id,designation
case:
a user may have more than one designation...
Problem:
*In EDIT section of users, the values are retrieved from the tables,
but for the designation all the designation are shown in checkbox style
with respected field autochecked..
*when the user changes the designation while checking the checkbox, then
there is difficulty in updating the designation
whats the solution?
i tried to delete the existing designation and inserted the fresh ones..
i dont know whether this method is perfect or not...
Any help and suggestions are warmly welcome
Posted: Fri Jan 19, 2007 7:37 pm
by Kieran Huggins
Can you paste a link to one of the pages?