Thank you for the quick response. Ill check the link!
2011/2/21 Christophe COEVOET <[email protected]>
> Le 21/02/2011 19:50, oscar balladares a écrit :
>
> Hi everybody.
>>
>> It may sound very weird to ask this question; but what I want to do is to
>> create a custom navigation menu.
>>
>> So I want to get the current requested controller's or bundle's name not
>> from a template but from the layout.
>>
>> I have to write the css class of a <li> element to highlight te current
>> controller dynamically according to the bundle.
>>
>> Im thinking about something like (in a twig template):
>>
>> {% if (app.request.bundle == "HelloBundle") %}
>> <li class="highlight" ><a href="path to the bundle index">Hello bundle
>> </a></li>
>> {% endif %}
>>
> the bundle name is not available directly (it is not available in the PHP
> code either).
>
> You should look at https://github.com/knplabs/MenuBundle It may help you
> to display your menu.
>
> --
> Christophe | Stof
>
> --
> 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