You may not think it now but your form IS related to a model ;-)
See Jonathan snooks example of a contact form:
http://snook.ca/archives/cakephp/contact_form_cakephp/
Jonathan creates a tableless model and defines the schema by hand.
That way you get all the benefit of cake's helpers
Hi All,
The core Form helper works great as long as you have a model behind
it, but what about forms that are not related to a model?
Is there any helpers that I can use in the view? Or do I just code
plain HTML?
Thanks!
--~--~-~--~~~---~--~~
You received this
On Tue, Aug 26, 2008 at 8:45 AM, Enrique Delgado
[EMAIL PROTECTED] wrote:
Hi All,
The core Form helper works great as long as you have a model behind
it, but what about forms that are not related to a model?
Is there any helpers that I can use in the view? Or do I just code
plain HTML?
Hey Enrique,
You could still use the regular forms:
?php echo $form-create('Search',array('url' = '/search','type' =
'get')) ?
?php echo $form-text('query',array('type' = 'textarea')) ?
?php echo $form-end('Search!') ?
On Aug 26, 11:45 am, Enrique Delgado [EMAIL PROTECTED]
wrote:
Hi All,
Thanks Samuel and validkeys.
Samuel, very true, I do like extending the functionality of CakePHP,
that is probably one of the best ways to go when we need something
more custom.
This time, I had totally overlooked the regular Form helper methods
like text(), password(), etc. Thanks validkeys