With this bundle you can easily use DOMPDF to generate pdf documents from anywhere in Symfony2