title: JSTL. How to call a function from <script> in c:set jstl tag?
body: <p>I just need something like this:</p>
  
  <pre><code>&lt;c:set var="cls" value="${myFunc(param)}"/&gt;
  
  .....
  
  &lt;script&gt;
      function myFunc(param) {
          if(param == true) {
              return "aaa";
          } else {
              return "bbb";
          }
      }
  &lt;/script&gt;
  </code></pre>
  
  <p>When I try it then get this error:</p>
  
  <blockquote>
    <p>org.apache.jasper.el.JspELException: /script.jsp(22,12) '${myFunc()}'
    Function [:myFunc] not found</p>
  </blockquote>