0
votes

I'm new to cakePHP I want to know if there's a way to validate a form partially as in JavaScript.

Situation:
I have a select box with 2 options - 1. free, 2. paid
When paid is chosen a text input field appears for a price.

Any ideas?

Thanks in advance.

1
Please explain some what in more detail. You can also hide the price text box when it click on free !! - Rikesh

1 Answers

0
votes

You can do custom validation rules. So, your form would validate differently, depending on if it's a paid user or a free one.

This link will give you some ideas of how to get started with it:

http://bakery.cakephp.org/articles/aranworld/2008/01/14/using-equalto-validation-to-compare-two-form-fields