Announcement Announcement Module
No announcement yet.
Manage HTML resources in Spring MVC Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Manage HTML resources in Spring MVC

    Is there any way to manage html resources in spring mvc ?
    similar to grails-resources.
    Link to grails resource :

  • #2
    Do you mean keeping (X)HTML files in the web application and bypassing the MVC view resolver for these files? If yes, and using Spring 3.x, you can add

        <mvc:resources location="/html/" mapping="/html/**" />
    to your *-servlet.xml file. Then, all resources accessed with URLs starting with /html/ will be directly served and not be handled by the view resolvers.


    • #3
      No. I mean managing (js and css files).
      How can i manage these files per page.
      For example : i want script_1 and script_2 on page_1.jsp
      i mention something like : LOAD_SCRIPT_1 which will loads script_1 and script_2

      i define that somewere in spring and then load this command LOAD_SCRIPT_1 which will load the scripts.