My first time I created from origin a web-app and I’m new on Spring MVC.
I created a Spring MVC project and works as well. Now I want to add twitter-bootsrrap and jquery to my project and use these. Bu I don’t know ho can I do that?
I use Intellij Idea.
I’ve to download bootstrap and jquery files and add to project not from the link source.
I’m using Spring MVC 4. Because of that I don’t use xml files for Spring configuration. I use anotations.
Could you help me please?
2
Answers
If you want to use the downloaded files take a look at Spring MVC – How to include JS or CSS files in a JSP page
If you use maven take a look at webjars.
Also search abit more here on stackoverflow. A lot of questions regarding this already…
webjars-in-spring-mvc
add this line in your class config :
in src/main/webapp/ create folders resources and add css js to this folder .
in your page jsp apply your css and js like this using jstl :