title: Make Bootstrap dropdown from loop in python/Django
body: <p>I'm trying to make a dropdown menu that shows a list of items from a loop. I can view the source for the page and the loop is generating links, but the drop down button doesn't appear to do (display) anything when clicked on.</p>
  
  <p>I am working with python 3 and Django. The template is below. </p>
  
  <pre><code>{% extends "a/header.html" %}
  
  {% block content %}
  
  
  &lt;div class="dropdown"&gt;
  
  &lt;button class="btn btn-default dropdown-toggle" 
  type="button" id="dropdownMenu1" data-toggle="dropdown" 
  aria-haspopup="true" aria-expanded="false"&gt;
  People
  &lt;span class="caret"&gt;&lt;/span&gt;
    &lt;/button&gt;
  
    &lt;ul class="dropdown-menu" aria-labelledby="dropdownMenu1"&gt;
  
      {% for group in object_list %}
          &lt;li&gt;&lt;a href="/a/people/{{group.id}}"&gt;{{group.name}}&lt;/a&gt;&lt;/li&gt;
  
      {% endfor %}
  
    &lt;/ul&gt;
  &lt;/div&gt;
  {% endblock %}
  </code></pre>