Hi nerdess.
If you want to return a string from a controller instead returning a twig
template you should:
return new Response('HI, Im a string');
Also you have to:
use Symfony\Component\HttpFoundation\Response;
in the imports of the controller.
2011/4/1 nerdess <[email protected]>
> That is really helpful to know though I am wondering.........what if
> the controller looks sth like this and returns a simple string but not
> a template:
>
> public function () {
>
> //do magic stuff
>
> return $bla
>
> }
>
> how can i echo out what's inside $bla in my twig-template?
>
> Thanks
> Sissi
>
> --
> If you want to report a vulnerability issue on symfony, please send it to
> security at symfony-project.com
>
> You received this message because you are subscribed to the Google
> Groups "symfony users" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/symfony-users?hl=en
>
--
If you want to report a vulnerability issue on symfony, please send it to
security at symfony-project.com
You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en