I am trying to assign the $this->render()
method to a method (this method displays google map infoWindow / baloon).
I use a method like this to create this infoWindow:
$infoWindow->setContent(<here goes the template>);
but passing it as follows:
$infoWindow->setContent($this->render('WmapFrontBundle:Place:infoWindow.html.twig'));
don't work at all. How can I assign a template to a variable or pass it to a method?
source share