In Spring MVC, following setup is being used.
1. A DispatcherServlet defined in web.xml
And then in jackspringmvcapp-servlet.xml
In the boxPrintLocations.jsp, I can call the boxlocation controller like this:
And it prints the JSON
string using the following statements in the console:
However, I want to use AJAX call (jQuery based) in my boxPrintLocations.jsp and wondering how can I change the BoxController to achieve this inside Spring MVC? I mean I want to use jQuery Ajax call to call an end point and then get the JSON.