[dev] form: num & size issues

steve mailling at gmx.co.uk
Mon Aug 11 06:36:08 PDT 2003


Hello,

I would like to use the Form.php API with the 'int' type. ie.
$attributes['socialsecurity'] = array(
     'label' => _("Social security number"),
     'type' => 'int',
     'required' => false
);

But I don't get the good size in the <input tag>

I think we need to change the following functions in lib/Form/Renderer.php:
_renderVarInput_number
_renderVarInput_int

Maybe the option could be inserted like this?:
$attributes['socialsecurity'] = array(
     'label' => _("Social security number"),
     'type' => 'int',
     'required' => false,
     'params' => array('size' => '9')
);

Do you have any idea how to di it or implement it?

Thank you

Steve



More information about the dev mailing list