View RSS Feed

Recent Blogs Posts

  1. Serving Static Content in Spring

    by , 11-27-2011 at 10:06 PM
    If you are concern you that DispatcherServlet will be handling static content requests, Spring has features that can help you to deal with this. Spring’s mvc namespace includes a <mvc:resources> element that handles requests for static content for you. In the following example, I show you how you can create an xml file that the DispatcherServlet can use to create an application context.

    Java Code:
    <?xml version="1.0" encoding="UTF-8"?> 
    <beans xmlns="http://www.springframework.org/schema/beans"
    ...

    Updated 11-30-2011 at 12:59 PM by Spring Framework

    Categories
    MVC