3

I'm using OpenLayers and GeoServer in combination with Apache for creating GIS-based WEB application.

I have created layers and styled them in GeoServer, but when I try to load those layers with OpenLayers as a WFS I don't get any result over the map. I read somewhere that HTML file should be added to the same host as GeoServer (for me it is localhost:82/geoserver).

I tried to put HTML file to "Tomcat 8.5\webapps\geoserver\data\www" but when I try to open http://localhost:82/geoserver/www/index.html I get HTTP Status 404 - description The requested resource is not available. I can open HTML files that were there before ol-demo.html and wfs-t.html.

Is there any suggestion what I should do?

  • does tomcat have read permission for the new files? – Ian Turton Dec 4 '16 at 11:32
  • I am not sure what you mean by that. How can I check that? This is some school project, so I am still learning a lot about this. I figured out that it possible to open HTML file over localhost if I add it to any folder in "Tomcat 8.5\webapps\", but not from GeoServer, what I need for getting this WFS. – Zoran Kokeza Dec 4 '16 at 16:08
  • A wfs doesn't provide a styled layer, just the data – nmtoken Dec 6 '16 at 14:58
1

The reason was that I had GeoServer installed twice, at first GeoServer alone and then another one that was in tomcat and it was making problems(tomcat stored all files at "wrong" place). After uninstalling of tomcat and geoserver, and installing tomcat again I can open file over localhost

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.