title: Django template for loop without duplicate buttons
body: <p>When I vote for more than one entry, the "Add Vote" button is duplicated for each entry in the for loop. Any ideas as to how I should fix the logic so the add vote button only appears once?</p>
  
  <pre><code>                    {{ user.get_profile.votes.all }}
  
                  {% for v in user.get_profile.votes.all %}
                      {% if v.entry = e.entry %}
                          &lt;form action="/profile/" method="post"&gt;
                          {% csrf_token %}
                          &lt;input type='hidden' name='entry_id' value='{{ e.id }}'&gt;
                          &lt;input type='hidden' name='project_id' value='{{ p.id }}'&gt;
                          &lt;input type='hidden' name='team_id' value='{{ t.id }}'&gt;
                          &lt;input type='submit' name="remove_vote" value='Remove Vote'&gt;
                          &lt;/form&gt;
                      {% elif v.entry != e.entry %}
                          &lt;form action="/profile/" method="post"&gt;
                          {% csrf_token %}
                          &lt;input type='hidden' name='entry_id' value='{{ e.id }}'&gt;
                          &lt;input type='hidden' name='project_id' value='{{ p.id }}'&gt;
                          &lt;input type='hidden' name='team_id' value='{{ t.id }}'&gt;
                          &lt;input type='submit' name="add_vote" value='Add Vote'&gt;
                          &lt;/form&gt;
                      {% endif %}
                      {% empty %}
                          &lt;form action="/profile/" method="post"&gt;
                          {% csrf_token %}
                          &lt;input type='hidden' name='entry_id' value='{{ e.id }}'&gt;
                          &lt;input type='hidden' name='project_id' value='{{ p.id }}'&gt;
                          &lt;input type='hidden' name='team_id' value='{{ t.id }}'&gt;
                          &lt;input type='submit' name="add_vote" value='Add Vote'&gt;
                          &lt;/form&gt;
                  {% endfor %}
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/dWZpd.png" alt="screenshot"></p>