Skip to main content
Topic: checkbox with php and MySQL (Read 1536 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

checkbox with php and MySQL

I have now been hamering my head against a wall for some days and bugged many ppl about this.
I have been working a little with php and mySQL now but checkboxes I just can't figure out.

This is what the code would look like if I did it as I would do text boxes and textareas:

<input type="checkbox" name="Permission" value="<?php echo $Permission ?>>

This however does not work.
If I manually put "checked" in the permission column in the SQL db ithe box is checked but then I can't uncheck it and have it saved.
I found that it reads it ok but it does not write "checked" or "" to the db as it should.

If anyone can help me with this I would be so very grateful.

Thanks and regards,
Jan.

 
SimplePortal 1.0.0 RC1 © 2008-2018