| Hi, I am working in an application that render layers on map. I am using Geoserver 2.11.2,PostgreSQL and Leaflet. I want to access layers in GeoJSON format by calling WFS service so that they can be used by Leaflet.My geoserver is running on *http://localhost:8080/geoserver* and my application that will call WFS service is on *http://localhost:8081*. I successfully enable JSONP in web.xml file. But when I changed in the following file to Enable CORS , that did not work. C:\Program Files (x86)\GeoServer 2.11.2\webapps\geoserver\WEB-INF\web.xml I uncomment the following lines and restart the geoserver. <filter-mapping> <filter-name>cross-origin</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <filter> <filter-name>cross-origin</filter-name> <filter-class>org.eclipse.jetty.servlets.CrossOriginFilter</filter-class> </filter> Then get the error attached. Please do help. |