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

groupelementtemplate inserting a 1

Details

Submitted2004-07-22 22:47 UTC
Fromwrbj7xl02 at sneakemail dot com
StatusBogus
PackageHTML_QuickForm
PHP Version4.3.8
OSLinux 2.4.18-10smp RH9
Roadmaps(Not assigned)

Comments

[2004-07-22 22:47 UTC] wrbj7xl02 at sneakemail dot com

Description:
------------
I am using a local installation of Quickform (QuickForm.php,v 1.139 2004/03/20), to develop with. When I posted my code to a production server, which was running the very latest of Quickform (QuickForm.php,v 1.144 2004/06/15), a bizzare thing happened.

I am setting a group template and a groupelementtemplate, in 1.139, things worked perfectly. In 1.14, quickform renderer is inserting a "1" in the middle of the template. I have checked and rechecked my code, and I can't find anything that would be emitting a one, especially in the middle of a dynamically generated table.

A "1" is being inserted at the end of the groupelementtemplate.

Reproduce code:
---------------
$renderer->setgroupelementtemplate('
<td valign="top">
<table border="0" width="100%" height="100%" cellspacing="0" cellpadding="3">
<tr>
<td valign="top">{label}</td>
</tr>
<tr>
<td valign="top">{element}</td>
</tr>
</table>
</td>
', $element_field );

The output is:
</td>
1
<td valign="top">

Expected result:
----------------
</td>
<td valign="top">

Actual result:
--------------
The output is:
</td>
1
<td valign="top">

[2004-07-22 22:58 UTC] wrbj7xl02 at sneakemail dot com

I've posted the entire function that is associated with this entry.

http://www.gammaworld.org/pear/pear-bug-1961.phps

I didn't post the entire class, I'm using a huge class to dynamically draw form elements for me. QF is awesome for that!

[2004-07-23 12:48 UTC] wrbj7xl02 at sneakemail dot com

Oh jeez.. Sorry.