title: How to put each loop value into separate divs in django
body: <p><a href="https://i.stack.imgur.com/0Gl14.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/0Gl14.png" alt="enter image description here" /></a></p>
  <p>Here's my html page. I want each 'question' to be placed in separate div to make them look nice.
  So I put in the following code:</p>
  <pre><code>{% for post in object_list %}
      &lt;div class=&quot;myDiv&quot;&gt;
      &lt;a href=&quot;{% url 'article' post.pk %}&quot;&gt;{{ post.title }}&lt;/a&gt; &lt;br&gt;- {{ post.author }} , {{ post.date.date }}&lt;br&gt;
      &lt;/div&gt;
  {% endfor %}
  </code></pre>
  <p>But here's what it did:</p>
  <p><a href="https://i.stack.imgur.com/gMlxv.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/gMlxv.png" alt="enter image description here" /></a></p>
  <p>It makes one big div and placing all the posts/questions in them. How do I separate them?</p>
  <p>Here's my css:</p>
  <pre><code>         .myDiv {
            background-color: #012B39;
            text-align: left;
            margin: left;
            width: 25%;
            }
  </code></pre>
  <p>Little help will be appreciated! THANKS</p>
  <p>P.S I will change the font colors to make them visible with the div.</p>