[drupal-devel] [feature] More flexibility for form_checkboxes and form_radios attributes

drumm drupal-devel at drupal.org
Fri Jul 29 19:57:17 UTC 2005


Issue status update for 
http://drupal.org/node/27804
Post a follow up: 
http://drupal.org/project/comments/add/27804

 Project:      Drupal
 Version:      cvs
 Component:    base system
 Category:     feature requests
 Priority:     normal
 Assigned to:  drumm
 Reported by:  drumm
 Updated by:   drumm
 Status:       patch

The attributes argument of form_checkboxes() and form_radios() is
currently used to apply the same attributes to each input tag. In some
cases you might want to have different attributes applied to each
checkbox or radio button. For example, this makes disabling some of the
checkboxes possible.


An example of the usage is

<?php
array('somekey' => array('disabled' => 'disabled'), 'someotherkey' =>
(...), ...)
?>




This patch also removes the br tag after each checkbox and radio
button. Drupal.css is used to set the display to block. br is a
presentational tag which often conflicts with using CSS to style
things.




drumm




More information about the drupal-devel mailing list