Hi all,
I'm generating a page with php. In this page i'm including a form with a lot of checkbox, several of this checkbox are checked an others not. So, when i clicked on submit button, only take the value from the checked box previously. Anyone could tell me why don´t get the others values?
I only need determinate which of this checkbox are checked or not in the next php page.
thanks in advance.
sorry by my english.
an easy question!!!
Moderator: General Moderators
That's the way selected options are shipped via html/http, as name=On
If you want to get multiple option instances of the select-element use something likeand you will get an array (with numerical indices) containing all checked options.
If you want to get multiple option instances of the select-element use something like
Code: Select all
<select name="mySelectї]">-
skull cowboy
- Forum Newbie
- Posts: 14
- Joined: Tue Jan 21, 2003 3:04 am
thanks
I´ll try with this.
Thanks.
Thanks.
-
skull cowboy
- Forum Newbie
- Posts: 14
- Joined: Tue Jan 21, 2003 3:04 am
another solution?
Ok, i tested your solution and it is ok, but it is possible to do the same thing with the checkbox control? Do you know another solution with chekbox control?
sorry, but i prefer use the checkbox control instead of select control for design reasons.
thanks again.
sorry, but i prefer use the checkbox control instead of select control for design reasons.
thanks again.
- twigletmac
- Her Royal Site Adminness
- Posts: 5371
- Joined: Tue Apr 23, 2002 2:21 am
- Location: Essex, UK
almost the sameI tried to explain it here: viewtopic.php?t=4396
Code: Select all
<input name="myCheckboxї]" value="1" /><br />
<input name="myCheckboxї]" value="2" /><br />
<input name="myCheckboxї]" value="3" /><br />
<input name="myCheckboxї]" value="4" /><br />