Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

initflow/djangocms-multimenus

Open more actions menu
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
33 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

djangocms-multimenus

This plugin requires:

Multiple named menus support for DjangoCMS

Authors

  • Wojtek Kloc
  • Grzegorz Biały

django-parler and django-treebeard integration based on code from: https://github.com/aldryn/aldryn-categories/

Installation

  1. Add 'multimenus' to INSTALLED_APPS in your Django project's settings file.
  2. python manage.py migrate multimenus.

Usage

First, create menu using panel in CMS main toolbar. See screenshots for details.

django-multimenus1

django-multimenus2

Template

Display menu with Menu ID: NAVBAR_TOP

{% load multimenus %}

<ul>
    {% show_multi_menu "NAVBAR_TOP" %}
</ul>

Templatetag parameters

{% show_multi_menu MENU_ID "template.html" include_self=True %}
  • you can override menu template using path as second parameter. Basic template code:
{% load multimenus %}

{% for item in items %}
<li>
    <a href="{{ item.get_url }}"{% if item.target %} target="{{ item.target }}"{% endif %}>{{ item.title }}</a>
    {% if item.get_children %}
    <ul>
        {% with items=item.get_children %}
            {% include template %}
        {% endwith %}
    </ul>
    {% endif %}
</li>
{% endfor %}
  • include_self - boolean

By default, multimenus lists children of item matched by Menu ID. You can set include_self=True to include element.

About

Multiple tree menus for DjangoCMS

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.