Development

#3528 (HTML attributes aren't applied to radio buttons via renderRow())

You must first sign up to be able to contribute.

Ticket #3528 (closed defect: fixed)

Opened 6 months ago

Last modified 6 months ago

HTML attributes aren't applied to radio buttons via renderRow()

Reported by: slickrick Assigned to: fabien
Priority: minor Milestone: 1.1.0 RC2
Component: form Version: 1.1.0 RC1
Keywords: Cc:
Qualification: Unreviewed

Description

If I attempt to apply an attribute to renderRow in a template, it is not parsed into the actual HTML tag.

Form Code:

$schema = new sfWidgetFormSchema(array(
 'is_enabled' => new sfWidgetFormSelectRadio(array(
   'choices' => array(1 => 'Yes', 0 => 'No'),       
   )),
  ));

Template Code:

<?php echo $form['is_enabled']->renderRow(array('onChange' => 'evalFunction()')); ?>

I'd expect the onChange attribute to be added to the radio button tags like it does for other form widgets, but it is not included. Note: the class attribute does work.

Change History

05/15/08 09:41:39 changed by FabianLange

  • status changed from new to closed.
  • resolution set to fixed.

(In [8974]) sfWidgetFormSelectRadio now merges attributes passed in correctly. Fixes #3528