function editPost($alias) { $post = new PostModel(); $currentPost = $post->findByAttr('alias', $alias); $this->view->addData($currentPost[0]); $this->view->make('edit'); }