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 #496

setDefaults with callback processes special characters wrongly

Details

Submitted2003-12-26 01:43 UTC
Fromaidan at virtualexplorer dot com dot au
StatusBogus
PackageHTML_QuickForm
PHP VersionIrrelevant
OSn/a
Roadmaps(Not assigned)

Comments

[2003-12-26 01:43 UTC] aidan at virtualexplorer dot com dot au

Description:
------------
HTML_QuickForm::setDefaults with a htmlentities callback function will result in special characters being converted twice!

For example:

$form->setDefaults($result[0], 'htmlentities');

Letters such as special n (n with a tilde), or any other international characters are first converted using the callback function to their ascii names, ñ, and when outputted, again converted to &ñ

If the data is called without using a callback function, the letters are not converted at all, and causes problems in displaying the form.