# menu\_rsc

Source: https://zotonic.com/docs/1332/menu_rsc

URI: https://zotonic.com/id/1332

Language: en



Return the menu to be displayed with a resource.

Checks the results of the <a href="/id/doc_notification_menu_rsc" class="doc-reference doc-reference-notification"><code>notification#menu_rsc</code></a> notification. If that returns undefined then the predicate `hasmenu` is used to find menus attached to the resource. The first in the list is returned by this filter.

If no menu is found then the menu resource id with name `main_menu` is returned.

Example:

```django
{% if id|menu_rsc as menu_id %}
    .. display the menu with id menu_id ..
{% endif %}
```

License: 

Attribution: 

Related resources: https://zotonic.com/api/agent/related/1332?language=en


## API access

- [API help](<https://zotonic.com/api-help>)
- [OpenAPI specification](<https://zotonic.com/openapi.json>)
- [This resource as JSON](<https://zotonic.com/api/agent/resource/1332?language=en>)
