Note that there are some explanatory texts on larger screens.

plurals
  1. POInternalResourceViewResolver doesn't load page from subfolder
    primarykey
    data
    text
    <p>under the webapp folder of my application i have a folder called <strong>meetingroom</strong> and in that folder i have a jsp page called <strong>viewrooms.jsp</strong></p> <p><strong>- DispatcherServlet</strong> configuration is as follows:</p> <pre><code>&lt;listener&gt; &lt;listener-class&gt;org.springframework.web.context.ContextLoaderListener&lt;/listener-class&gt; &lt;/listener&gt; &lt;context-param&gt; &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt; &lt;param-value&gt; classpath:spring/config/applicationContext.xml &lt;/param-value&gt; &lt;/context-param&gt; &lt;servlet&gt; &lt;servlet-name&gt;spring&lt;/servlet-name&gt; &lt;servlet-class&gt;org.springframework.web.servlet.DispatcherServlet&lt;/servlet-class&gt; &lt;init-param&gt; &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt; &lt;param-value&gt;classpath:spring/config/applicationContext.xml&lt;/param-value&gt; &lt;/init-param&gt; &lt;load-on-startup&gt;1&lt;/load-on-startup&gt; &lt;/servlet&gt; &lt;servlet-mapping&gt; &lt;servlet-name&gt;spring&lt;/servlet-name&gt; &lt;url-pattern&gt;/meetingroom/*&lt;/url-pattern&gt; &lt;/servlet-mapping&gt; </code></pre> <p><strong>- InternalResourceViewResolver</strong> bean:</p> <pre><code>&lt;bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"&gt; &lt;property name="prefix" value="/"/&gt; &lt;property name="suffix" value=".jsp"/&gt; &lt;/bean&gt; </code></pre> <p><strong>- Controller:</strong></p> <pre><code>@Controller @RequestMapping("/viewrooms.jsp") public class ViewRooms { @RequestMapping(method = RequestMethod.GET) public String get() { log.debug("######## GET METHOD FOR VIEW ROOMS ########"); return "meetingroom/viewrooms"; } } </code></pre> <ul> <li>How i am accessing the page: <code>http://localhost:8081/MyAPP/meetingroom/viewrooms.jsp</code></li> </ul> <p><strong>ISSUE:</strong> the controller get method is getting called in infinite loop and the page is not rendered.</p> <p>please advise why it's not working, thanks.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload