php - Get checkbox value in a html form -


the part of form post goes this:

<input type="checkbox" id="somevalue1" value="somevalue1" class="css-checkbox" name="checkbox1" /> <input type="checkbox" id="somevalue2" value="somevalue2" class="css-checkbox" name="checkbox2" /> 

now want make php/mysql script posts every selected value, if somevalue1 selected , form posted puts somevalue1 in table, if both values selected puts somevalue1 in table and puts somevalue2 in table.

summed up: want values of checked checkboxes

change name checkbox checkbox[]. change single value in $_request array of values in $_request.


Comments

Popular posts from this blog

php - render data via PDO::FETCH_FUNC vs loop -

c++ - OpenCV Error: Assertion failed <scn == 3 ::scn == 4> in unknown function, -

The canvas has been tainted by cross-origin data in chrome only -