title: Restful Path Parameters in Spring MVC 3
body: <p>Is it possible to: set a URI template in the mvc:view-controller element of the *-servlet.xml file or in a controller method and then use/get that path parameter <em>in a jsp</em>? </p>
  
  <p>I understand that using @PathVariable in a controller method will give me access to the path parameter <em>in that controller method</em>. But how can I gain access to the path parameter <em>in the jsp</em>? </p>
  
  <p>For example, is it possible to do something like:</p>
  
  <p><strong>*-servlet.xml file:</strong></p>
  
  <pre><code>&lt;beans...&gt;
  &lt;mvc:view-controller path="/home" view-name="home"/&gt;
  &lt;mvc:view-controller path="/home/{error}" view-name="home"/&gt;
  &lt;/beans&gt;
  </code></pre>
  
  <p><strong>jsp file:</strong></p>
  
  <pre><code>&lt;c:if test="${not empty param['error']}"&gt;
  &lt;span class="error"&gt;You have an error...&lt;/span&gt;
  &lt;/c:if&gt;
  </code></pre>