title: In spring/mvc using if-then-else statement on the "model" in a jsp page
body: <p>i've this methodo in my servlet:</p>
  
  <pre><code>@Override
  protected ModelAndView handleRequestInternal(HttpServletRequest request, HttpServletResponse response) throws Exception {
  
      Map&lt;String, Object&gt; myModel = new HashMap&lt;String, Object&gt;();
  
      [...do something...]
  
      model.put("msg","a message");
  
      return new ModelAndView("myPage", "model", myModel);
  
  }   
  </code></pre>
  
  <p>Now in my myPage.jsp i want to do an if-then-else on ${model.msg} and i've tryed to use JSTL in this way:</p>
  
  <pre><code>        &lt;c:choose&gt;
              &lt;c:when test="${!empty model.msg}"&gt;
                  &lt;p&gt; not empty &lt;/p&gt;
              &lt;/c:when&gt;
              &lt;c:otherwise&gt;
                  &lt;p&gt;empty&lt;/p&gt;
              &lt;/c:otherwise&gt;
          &lt;/c:choose&gt;
  </code></pre>
  
  <p>But i get this warning and error: "test does not support run time expressions"</p>
  
  <p>can i've some help? Thanks</p>