title: Spring : How to show image in thymeleaf from database
body: <p>I'm doing project with Spring Boot+Spring Data+Spring MVC.I want to show image from database to thymeleaf but image not displayed. This is my code</p>
  
  <pre><code> &lt;span th:each="room,iterStat : ${room}"&gt;
                      &lt;div class="col-md-3 md-col"&gt;
                          &lt;div class="col-md"&gt;
                              &lt;a href="single.html" class="compare-in"&gt;&lt;img th:src="@{/static/images/${room.image}}" alt="" /&gt;
  
                              &lt;/a&gt;    
                              &lt;div class="top-content"&gt;
                                  &lt;h5&gt;&lt;a href="single.html"&gt;&lt;tr th:text="${room.name}"&gt;&lt;/a&gt;&lt;/h5&gt;
                                  &lt;div class="white"&gt;
                                      &lt;a th:href="@{/room/{id}/book(id=${room.id})}" class="hvr-shutter-in-vertical hvr-shutter-in-vertical2"&gt;BOOK&lt;/a&gt;
                                      &lt;p class="dollar"&gt;&lt;span class="in-dollar"&gt;$&lt;/span&gt;&lt;span&gt;2&lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;/p&gt;
                                      &lt;div class="clearfix"&gt;&lt;/div&gt;
                                  &lt;/div&gt;
                              &lt;/div&gt;                          
                          &lt;/div&gt;
                      &lt;/div&gt;
                       &lt;/span&gt;
  </code></pre>
  
  <p>I save image with name image in database and i save image in folder ../static/images .. When I copy images name in database instead of <strong>${room.image}</strong> , image will display..I don't know why</p>