trunk
This commit is contained in:
1 parent
11cc1b9dd1
commit
7bc0e46305
162 files changed
+19744
No files matched your search
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
|
||||
class AddPostForm extends CFormModel
|
||||
{
|
||||
public $title;
|
||||
public $text;
|
||||
public $image;
|
||||
|
||||
|
||||
/**
|
||||
* Declares the validation rules.
|
||||
* The rules state that username and password are required,
|
||||
* and password needs to be authenticated.
|
||||
*/
|
||||
public function rules()
|
||||
{
|
||||
return array(
|
||||
array('title, text, image', 'required'),
|
||||
array('image', 'file', 'types'=>'jpg, gif, png'),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user