Started re-write in Symfony2