Here, I use knpsnappybundle to generate pdfs. I want to generate a pdf of one of my pages HTML.twig. Everything goes well except GoogleMap. My pdf is created well as it should, all my data is provided without any problem except my googlemap. (of course my map appears well on HTML.twig)
I use ivory-google-map to generate my maps.
side Controller
$html = $this->renderView('TriangleClientBundle:Pdf:fiche_technique_acteur_pdf.html.twig',
array(
'map' => $map
));
//return new Response($html);
return new Response(
$this->get('knp_snappy.pdf')->getOutputFromHtml($html),
200,
array(
'Content-Type' => 'application/pdf',
'Content-Disposition' => 'attachment; filename="fiche_technique '.$nom.'.pdf"'
)
);`
Side html.twig
{{ google_map(map) }}