what will be vaule for the ratio button "All"

i have form field with ratio button . as my mysql database my all data row has a column named status where values like 1, 2, 3 etc.

to get status, my form has ratio button which specify the status. i want all data whatever its status is . as for i make the form field like that : what will be vaule for the ratio button “All”…

    <div class="form-group">
                        <label for="exampleId">Status</label>
                        <div class="radio">
                            <label><input type="radio" name="status" value="1" checked>All</label>
                                $table = "status_details";
                                $order = "ASC";
                                $column = "name";
                                $datas = getTableDataByTableName($table, $order, $column);
                                foreach ($datas as $data) {
                            <label><input type="radio" name="status" value="<?php echo $data->id; ?>"><?php echo $data->name; ?></label>
                            <?php } ?>


I am not sure what you are asking, but, I will assume you need to know how to pull in one value out of several in a radio button… This is an example of two buttons linked to one field…

<input type="radio" name="status" value="1" checked>
<input type="radio" name="status" value="2" checked>

Since both buttons have the same name, they are linked to each other. Only one button will be checked.
If the second button is selected, the first one is un-checked. When reading the posted data, only one is

If you are asking how to use another button to link to all buttons, just make that value a unique one.
In your example, you can use zero ( 0 ) as it’s value and save it. In your code, you would need to check
for zero and if so, it means ALL. You can use any value outside the range of the live buttons. Also, this
depends on how the column “name” is set in your database. If it is INT or DEC, then use zero, if it is
a CHAR or TEXT field, then use ALL. Such as:

<input type="radio" name="status" value="0" checked>
<input type="radio" name="status" value="ALL" checked>
Sponsor our Newsletter | Privacy Policy | Terms of Service