Hi All,
I have been able to insert a checkbox value into my database. The problem i am now facing is how to retrieve the value of the checkbox in the form of TICK.
Your help will be much appreciated.
Regards.
2 replies to this topic
#1
Posted 24 January 2011 - 07:12 AM
|
|
|
#2
Posted 24 January 2011 - 10:27 AM
well to make a check box pre-selected you do : <input type="checkbox" name=myBox value="value" checked>
So you want to alter the state of checked . To do that you will use a if statement.
than when you write that line again:
So you want to alter the state of checked . To do that you will use a if statement.
if($myChecks['check'] == true)
{
$checked = "checked";
}
than when you write that line again:
<input type='checkbox' name=mybox value='value' <?php echo $checked; ?> >
#3
Posted 24 January 2011 - 01:39 PM
EDIT: nvm, remove this post please (zeroradius has offered the correct solution).
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account


Back to top









