Tuesday, March 31, 2009

Re: form select/javascript

 echo $form->input('Model.field', array('onclick'=>'someAction()', 'label'=>'', 'minYear' => '1910', 'maxYear' => '2010'));

2009/3/31 mscdex <mscdex@gmail.com>

On Mar 31, 12:18 pm, Kalt <pierre.fring...@gmail.com> wrote:
> echo $form->dateTime(
>         'fieldname',
>         'DMY',
>         'NONE',
>         null,
>         array(
>                 'minYear' => 1983,
>                 'maxYear' => date('Y')
>         ),
>         false
> )

You can also do:

echo $form->year('Model.fieldname', 1983, date("Y"), null, array(),
false);




--
Juan Carlos Michaca Lucero
PAASEL
Consultoría en Matemáticas Aplicadas
Insurgentes Sur 1700 Despacho 102
Col. Florida C.P, 01030
Deleg. Alvaro Obregón, México D.F.
Tel. + 52 (55) 5663 4175
http://www.paasel.com
juan.michaca@paasel.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: