Bug #7148 [NEW]: Checked attribute alway true for radio button
| From: | e dot a dot schultz at gmail dot com | Date: | Fri, 17 Mar 2006 23:09:43 +0000 |
| Subject: | Bug #7148 [NEW]: Checked attribute alway true for radio button | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-7684@lists.php.net to get a copy of this message | ||
From: e dot a dot schultz at gmail dot com
Operating system: Red Hat Entiprise 4
Package version:
PHP version: 4.3.9
Package: Documentation
Bug Type: Bug
Bug description: Checked attribute alway true for radio button
Description:
------------
When created through a HTML_QuickForm object a radio Element's checked
attribute will always remain true. This is the case even after the
setChecked(false) method has been called.
Test script:
---------------
$form = new HTML_QuickForm( "test", "post", "index.php");
$radio = $form->createElement("radio");
$radio->setName("tester");
$radio->setText("Radio button to test");
$radio->setChecked(false);
$form->addElement($radio);
$form->display();
Expected result:
----------------
The radio button 'tester' should not be selected by default and the HTML
tag should not have a checked="checked" attribute.
Actual result:
--------------
The radio button 'tester' is selected by default and the HTML tag has a
checked="checked" attribute.
--
Edit bug report at http://pear.php.net/bugs/bug.php?id=7148&edit=1
--