PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » HTML » HTML_QuickForm » Bug #4401

Problem with select menu order of date fields.

Details

Submitted2005-05-21 21:29 UTC
Frommosh at tobt dot de
StatusWont fix
PackageHTML_QuickForm
PHP Version4.3.1
OSSuSe Linux dd6422 2.4.21-2
Roadmaps(Not assigned)

Comments

[2005-05-21 21:29 UTC] mosh at tobt dot de

Description:
------------
The problem with the select menu order of date fields is caused in file HTML/Quickform/date.php at line 353. The bug only occurs on the webserver of my ISP running SuSE Linux and PHP 4.31. On my localhost running WinXP/PHP 5.04 everything works as supposed.

Reproduce code:
---------------
I needed to change

$options = array($this->_options['emptyOptionValue'] => $this->_options['emptyOptionText']) + $options;

to

$options = array_merge(array($this->_options['emptyOptionValue'] => $this->_options['emptyOptionText']), $options);

because otherwise the "emptyOption" has been placed at the end of the list and not as first option as supposed!

Expected result:
----------------
The "emptyOption" should be the first option in the list.

Actual result:
--------------
But it is placed at the end of the select menu.