title: Responsive images using wagtail image tag
body: <p>I want an image to sit in a div which is 50% screen width ( with max width 800px for image in div) until 640px screen width where the div is 100%. I want the image to change height and width with the div. I want the whole image to always be shown. At the minute neither is changing and its messing up the responsiveness of the whole page. Everything is being pushed to the right.</p>
  
  <pre><code>&lt;tr class="fadeInBlock"&gt;
    &lt;td&gt;
      &lt;!--div for image of architecture--&gt;
      &lt;div class="homeInfo5"&gt;
        {{ page.architecturalText|richtext }}
      &lt;/div&gt;
  
  
    &lt;/td&gt;
    &lt;td&gt;
      &lt;div class="homeIm4"&gt;
        {% for item in page.gallery_images.all %} {% image item.image width-500 class="responsive"%}
        &lt;p&gt;{{ item.caption }}&lt;/p&gt;
        {% endfor %}
      &lt;/div&gt;
    &lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>
  
  <pre><code>.homeIm4 {
      height: auto;
      float: left;
  }
  
  .responsive {
    width: 100%;
    max-width: 250px;
    height: auto;
  }
  
  
  @media all and (max-width:640px) {
    table,
    thead,
    tbody,
    th,
    td,
    tr {
      display: block;
    }
  }
  </code></pre>
  
  <p>In the image tag I have tried min max width original and fill. Nothing I've tried has worked. Without the image the responsiveness of the page is fine with just the text field.</p>
  
  <p>I know about this link but it hasnt helped.
  <a href="https://www.w3schools.com/howto/howto_css_image_responsive.asp" rel="nofollow noreferrer">https://www.w3schools.com/howto/howto_css_image_responsive.asp</a></p>