title: Adding parameters from a map to a URL tag
body: <p>I want to add a variable list of parameters to a Struts2 URL tag. I have a map of the parameters (name value pairs) in an object in the session. I'm struggling to find a good approach to this. Here is the relevant JSP code: </p>
  
  <pre><code>    &lt;s:iterator value="%{#session['com.strutsschool.interceptors.breadcrumbs']}" status="status"&gt;
      &lt;s:if test="#status.index &gt; 0"&gt;
          &amp;#187;
      &lt;/s:if&gt;
      &lt;s:url id="uri" action="%{action}" namespace="%{nameSpace}"&gt;
              &lt;s:param name="parameters" value="%{parameters}"/&gt;
      &lt;/s:url&gt;
      &lt;nobr&gt;&lt;s:a href="%{uri}"&gt;&lt;s:property value="displayName"/&gt;&lt;/s:a&gt;&lt;/nobr&gt;
  &lt;/s:iterator&gt;
  </code></pre>
  
  <p>The parameters variable is a Map that contains the params. This, of course does not work but I cannot see a way to approach this at the moment. I'm thinking at the moment that I might need a custom freemarker template for this. Can anyone suggest a better way?</p>