Reputation: 36404
I have downloaded json library , and my jsp pages are in tomcat/webapps/star/index.jsp .
So where should I extract the json libraries so that the json code contained in index.jsp works ?
Upvotes: 1
Views: 2861
Reputation: 1108782
As usual, 3rd party libraries in JAR flavor should go in Webapp/WEB-INF/lib
folder. This folder is taken in the webapp's default runtime classpath. If you'd like to share the same libs among multiple webapplications on the same server, then rather drop it in Tomcat/lib
folder.
By the way, such JSON libraries only converts Java objects to JSON strings and vice versa. They have completely nothing to do with JSON in the JSP side. It's JavaScript who's responsible for that part.
Upvotes: 1