php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #873 problem with checkboxes?
Submitted: 1998-10-26 02:08 UTC Modified: 1998-10-26 05:56 UTC
From: junkmail at jc dot nu Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 3.0.3 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: junkmail at jc dot nu
New email:
PHP Version: OS:

 

 [1998-10-26 02:08 UTC] junkmail at jc dot nu
in form file:
  <input type="Checkbox" name="test" value="one" align="LEFT">one<br>
  <input type="Checkbox" name="test" value="two" align="LEFT">two<br>
  <input type="Checkbox" name="test" value="one" align="LEFT">three<br>

  -or-

  <select name="test" size="3" multiple><option value="one">one
     <option value="two">two
     <option value="three">three
</select>


in submit file:

while (list($var, $value) = each($HTTP_POST_VARS))
{
 echo "$var = $value<br>\n";
}
echo $test;

---

In the above example, if I were to select one and three, it would generally only return "three" in the resulting script.

Generally, this will result in the last seleted value; it should result in a comma delited list of all selected values, shouldn't it? Help!!



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-10-26 05:56 UTC] rasmus
The first instruction on the bug submittal page is to scan the FAQ.  This is FAQ #5.9
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sat Jul 05 04:01:35 2025 UTC