1

I have 3 layers of vector polygons(about 80 polygons - 1MB geojson each but I haven't simplified any yet) displaying school territories (kindergardens, primary and secondary education) and I want to produce a web map so that the user would know in which school his/her children "belong": The plan is:

  1. I enter my address
  2. A marker on the address is created
  3. A radius of 10 meters is created around the marker
  4. The map highlights the polygons in which my address (marker with radius of 10 meters) lies in or are near (20 meters) to the point
  5. I am informed about the name of each of the polygons my address(marker with radius of 10 meters) falls in.

The polygons may sometimes be more than 3 because some territories overlap another.

Can I implement all this tasks by using a client-side library (leaflet, openlayers) or should I implement this project by using server-side geoserver?

Would I be able to create the radius around the marker point? Would I be able to manage the overlapped polygons so that all of them are selected when a point lies within them and not just the top one?

Any ideas to help me start?

  • That is quite a few questions. Are you expecting to do the address seach using OpenLayers/Leaflet too? You can certainly do point in polygon and circle drawing quite easily in OpenLayers/Leaflet, but, obviously, you will need to have all the vectors loaded client side, so performance will depend on the size/complexity of your features, which you haven't specified. The multi-select of overlapping polygons requires you to write code (I have done this). – John Powell Dec 7 '14 at 9:27
  • Thanks for your reply. Yes I will do my geocoding by using openlayers/leaflet and I know about point in polygon. But if I do the circle drawing as you suggest can I then use it to check which polygon it lies within? I thought that point in polygon works only for points and not for shapes(svg?). By the way each layer contains about 80 polygons(about 1MB in geojson file but I haven't simplified the polygons yet, so it would be much less). So if you say that the multi-selection is doable I think I will go client-side. If the performance suffers I will create 3 different webpages for my 3 layers. – geoSAM Dec 7 '14 at 16:37
  • Just to update I did everything I wanted by using leaflet with cartodb's postgis capabilities to get the overlapping geometries. – geoSAM Jan 29 '15 at 18:38

Your Answer

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

Browse other questions tagged or ask your own question.