title: Using html button to change status of data
body: <p>I'm building an ecommerce site with django, and i wanted to create a button that would signal that an order had already been delivered.</p>
  
  <p><img src="https://i.stack.imgur.com/EpDNZ.png" alt="enter image description here"></p>
  
  <p>I'm pretty sure you can acheive this with a checkbox, but i wanted to use a button, because it would be easier to click when using a tablet.</p>
  
  <p>I want the button to also be "unclickable" in case someone accidentally clicked a button for a wrong order.</p>
  
  <p>Do i need to make a form in the html? or is there an easier way to do it.</p>
  
  <p>this is my html:
      
      
      </p>
  
  <pre><code>Order page
  
  &lt;table&gt;
      &lt;tr&gt;
          &lt;td&gt;#&lt;/td&gt;
          &lt;td&gt;Name&lt;/td&gt;
          &lt;td&gt;Email&lt;/td&gt;
          &lt;td&gt;Phone&lt;/td&gt;
          &lt;td&gt;Order&lt;/td&gt;
          &lt;td&gt;Order Quantity&lt;/td&gt;
          &lt;td&gt;Delivered&lt;/td&gt;
      &lt;/tr&gt;
  
      {% for ord in orders %}
          {% for food in ord.orderitem_set.all %}
  
          &lt;tr&gt;
              {% if forloop.counter == 1 %}
                  &lt;td&gt;{{ord.pk}}&lt;/td&gt;
                  &lt;td&gt;{{ord.user.first_name}}&lt;/td&gt;
                  &lt;td&gt;{{ord.user.email}}&lt;/td&gt;
                  &lt;td&gt;{{ord.user.get_profile.phone}}&lt;/td&gt;
  
              {% else %}
                  &lt;td colspan="4"&gt;&lt;/td&gt;
              {% endif %}
  
                  &lt;td&gt;{{food.name}}&lt;/td&gt;
                  &lt;td&gt;{{food.quantity}}&lt;/td&gt;
  
              &lt;td&gt;{% if forloop.counter == 1 %} &lt;button type="button"&gt;Delivered&lt;/button&gt; {% endif %}&lt;/td&gt;
          &lt;/tr&gt;
          {% endfor %}
      {% endfor %}
  
  &lt;/table&gt;  
  
  
  &lt;/body&gt;
  &lt;/html&gt;  
  </code></pre>