You should now have an understanding on how to get started with the combination of Zend and Doctrine. Though this tutorial handles really only the basics, it lays a foundation of where to start.
This is very similar to adding and editing a post.
First up, we’re going to add the route so we can delete a post by creating the delete route into the
view child routes.
By now the process of creating a new action should be familiar. First up we’re going to create the route, then the view, then the action, followed lastly with whatever is needed for the action and the view.
Now that we have an
InputFilter setup, we can create the
When creating forms we’re going to be following the same principles we’ve followed earlier, mainly DRY and separation of concerns.
Now that we have an overview and a view, we’re going to create the possibility to create a new post.
Before we can view a post, even though the
view.phtml file is present, we have to include it in our routing.
First, let’s update our layout to link to the blog module, so that when we visit the homepage we don’t have to type in the URL to go the blog.
Now that we have set up the Post entity and have some data in the database, let’s show this data in the index view we created earlier.