I have a simple form with some switches. I want to disable some of the switches, is this possible?
$sixMonths = true; $twelveMonths = true; $twentyfourMonths = false; echo $this->McForm->create('Wizard', array ('url'=>'/wizard/create')); $options = array('24' => '24 months','12' => '12 months', '6' => '6 months'); $attributes = array('legend' =>false, 'default' => '6'); echo $this->McForm->radio('period', $options, $attributes); echo $this->McForm->submit('Save'); echo $this->McForm->end();
So, in this case, I would turn off the first switch and turn on the other two.
I know I could do it with jQuery, but I would rather do it without using it, is this possible? Any ideas?
Thanks!
source share