On Feb 19, 2007, at 3:54 PM, apacheuk wrote:

>
>
> OK, I might be missing something here....
>
> I have a form based on my model and this is working wonderfully I  
> can save
> records and edit them.
>
> I'm having trouble in that I want to include a checkbox on the form  
> that has
> no DB field or model, but I want to use the value of that checkbox  
> to do
> some additional stuff in the controller when I submit the form.
>
> How do I include this checkbox if it doesn't have a an assciated  
> field in
> the model and access from the controller?

Just use the HtmlHelper methods as normal:

<?php echo $html->checkbox('Model/fakeField'); ?>

And use it in the controller at:

$this->data['Model']['fakeField'];

Is that what you're after?

-- John

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to