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 » Database » DB_DataObject_FormBuilder » Bug #3233

Add option to specify label for selectAddEmtpy

Details

Request #3233Add option to specify label for selectAddEmtpy
Submitted2005-01-19 00:56 UTC
Fromjamie dot alessio at ucop dot edu
Assignedjustinpatrin
StatusClosed
PackageDB_DataObject_FormBuilder
PHP Version5.0.3
OSn/a
Roadmaps(Not assigned)

Comments

[2005-01-19 00:56 UTC] jamie dot alessio at ucop dot edu

Description:
------------
It would be nice to be able to specify a label that is used if the 'selectAddEmpty' option is true. Perhaps a new option called 'selectAddEmtpyLabel' could be used? The relevant code change is in FormBuilder.php at line 1641. Change:

if ($selectAddEmpty) {
$list[''] = '-- Select --';
}

to something like:

if ($selectAddEmpty) {
if($selectAddEmptyLabel)
$list[''] = $selectAddEmptyLabel;
else
$list[''] = '';
}

[2005-01-19 17:58 UTC] jamie dot alessio at ucop dot edu

I grabbed the latest code from CVS to test this and the added code works as expected. Thanks.