Archive for October, 2011

Symfony2: Obtaining the Request Object

In this quick post I am looking at how to obtain the Request object in a Symfony2 controller as a service. This is actually covered in the docs but in one of the earlier introductory pieces and so is easily missed or forgotten about by the time you actually need to know it. I know [...]

Symfony2: Routing to Controller as Service with Annotations

A very quick post as I couldn’t find anything documenting this yet (I will submit this to the docs also). If you want to use the combination of annotations for routing and also make your controllers into services then you can by specifying the service id in the class route: <?php   namespace ExampleBundle\Controller;   [...]

Symfony2: Doctrine Migrations and ACL tables

Edit: This is an issue with Symfony 2.0.x and looks to have been resolved for 2.1, please see Denderello’s comment below for more details If you use Doctrine migrations in a Symfony2 app then one difficulty you may run into is with database tables that do not relate to your entities. The doctine:migration:diff command will [...]

Subscribe to RSS Feed Follow me on Twitter!