Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

My Map web app reads client list from SQL server and for each client it draw points on a different layer so that the user could turn on and off that layer and see his entire customers. Problem is that once I have around 80+ layer than popups are appearing below the layers. Is there a workaround how I can show different features and turn them on / off without screwing with the popups ?

share|improve this question
add comment

1 Answer

up vote 3 down vote accepted

You should have all those points in a single layer. And set the visibility for each feature instead of layer.

share|improve this answer
    
So... How do I associate the points to customers? so when I uncheck a customer , some points go visible = false; –  Alophind Nov 13 '12 at 4:28
1  
you need a filter on customer id (or something). See openlayers.org/dev/examples/cql-format.html for an example –  iant Nov 13 '12 at 8:36
    
You can also store the customerid in feature.attributes.customerid If the user unchecks a customer, loop through the features do visible = false if it is unchecked. –  CaptDragon Nov 13 '12 at 16:32
    
Thanx Capt. Good idea. –  Alophind Nov 14 '12 at 10:23
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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