Creating drop-down based on data from database

Hi Guys,
Im just a beginner,
But I want to make instead of this side menu a dropdown menu.
As you can see, it is database driven, so it takes out everything from the database since we can make news “brands” to choose from.
But if I make a dropdown, bootstrap creates one dropdown menu for each brand.
And how do I make a second dropdown based on the brand you choose in the first dropdown?

```

merken

{% for item in brandnavigation|default(false) %}
{{ item.brand.brandname }}
{% if menubrands is defined %} {% for model in menubrands %} {% if model.brand.brandname == item.brand.brandname %}
{{ model.name}}
{% endif %} {% endfor %} {% else %} {% for model in branditem|default(false) %} {% if model.brand.brandname == item.brand.brandname %}
{{ model.name}}
{% endif %} {% endfor %} {% endif %} {% endfor %}
<do not remove the three backticks above>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.