title: How to use only certain validation set for validating data in Cake PHP?
body: <p>I was trying to validate my User model data and I came upon this problem.</p>
  
  <p>Say i have the following validation rules, stored in $validate variable:</p>
  
  <pre><code>var $validate=array(
          "username" =&gt; array(
              "usernameCheckForRegister" =&gt; array(
                  "rule" =&gt; ..., 
                  "message" =&gt; ...
              ),
              "usernameCheckForLogin" =&gt; array(
                  "rule" =&gt; ...,
                  "message" =&gt; ...
              )
          ),
          //rules for other fields
      );
  </code></pre>
  
  <p>In the UsersController controller, I have two actions: register() and login().
  The problem is, how do I validate the username field in the register() action using ONLY the usernameCheckForRegister rule, and how do I validate the username field in the login() action, using the other rule, usernameCheckForLogin?
  Is there any behaviour or method in CakePHP which allows me to choose which set of rules to apply to a form field when validating?</p>
  
  <p>Thank you in advance for your help!</p>