public function rules()
{
// NOTE: you should only define rules for those attributes that
// will receive user inputs.
return array(array('name, website', 'required'), array('sort_order', 'numerical', 'integerOnly' => true), array('name, en_name', 'length', 'max' => 100), array('website', 'length', 'max' => 200), array('image', 'length', 'max' => 255), array('image', 'safe'), array('id, name, website, sort_order', 'safe', 'on' => 'search'));
}