Created
July 15, 2009 09:08
-
-
Save jawngee/147600 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<? | |
class PostController extends Controller | |
{ | |
/** | |
* [[ | |
* view: 'post/edit' | |
* ]] | |
*/ | |
public function create() | |
{ | |
return array( | |
'post' => Model::Instance('blog.post'), | |
'mode' => 'create' | |
); | |
} | |
public function edit($post_id) | |
{ | |
// insert code here | |
return array( | |
'post' => $post, | |
'mode' => 'edit' | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment