I have created MVC application.
I want to include js or css file into jsp.
My static files ar under:
- webapp -js/jquery.js -WEB-I
Use spring JSTL tags to include external script files or style sheets. First you should include the the taglib in JSP as follows.
<%@ taglib uri="http://www.springframework.org/tags" prefix="spring"%>
Then you can include extenal script file using,
<script type="text/javascript" src="<spring:url value="/js/jquery.js"/>"></script>