Browse Source

Merge pull request #695 from Jomaanro/master

[doc] Correct validation rule in model
tags/2.0.0-beta
Qiang Xue 12 years ago
parent
commit
4e1264efbc
  1. 4
      docs/guide/model.md

4
docs/guide/model.md

@ -237,8 +237,8 @@ function rules()
{
return array(
// rule applied when corresponding field is "safe"
array('username', 'length', 'min' => 2),
array('first_name', 'length', 'min' => 2),
array('username', 'string', 'min' => 2),
array('first_name', 'string', 'min' => 2),
array('password', 'required'),
// rule applied when scenario is "signup" no matter if field is "safe" or not

Loading…
Cancel
Save