1
vote
1answer
26 views

Adding vector layer over WMS using OpenLayers?

I am trying to add vector layer to my map from a GeoJSON file stored in the same directory as my maps index.html. However It wont work. Is there something wrong with my syntax? My code: ...
1
vote
1answer
39 views

In OpenLayers 3, how do I draw an extent as a LinearRect?

In OpenLayers 2, this was an easy feat. I was able to simply instantiate a LinearRect given the coordinates of my BoundingBox, and then add the LinearRect as a feature to a vector layer I had added to ...
1
vote
0answers
17 views

Zoom to a vector feature in a vector layer

I am using OpenLayers+GeoServer and I have a vector layer in a map with some features I would like to make a zoom and show the map centered in one of these features that I can get by ID. How can I do ...
1
vote
0answers
42 views

OpenLayers - Add points at vertices of line while drawing line

I would like to create points while I draw a line on my map in OpenLayers. That is, at each vertices of a line and at the end points there is a shape like a square, circle, or diamond. I have this ...
1
vote
0answers
20 views

Openlayers text symbology is not being shown

I have a Vector Layer in a .json file: { "type" : "FeatureCollection", "features": [ { "type": "Feature", "properties": { "Station_Id":107, "NAME":"ARDEBIL(F)","ELEVATION":"1314.3"}, ...
2
votes
0answers
33 views

Adding feature to GeoServer vector layer using WFS-T in absence of fid index?

I want to add a feature to GeoServer vector layer with WFS-T. When I use saveStrategy.save(), an error returned that said: java.io.IOException: current fid index is null, next must be called ...
1
vote
0answers
29 views

Create vector layer from feature collection in OpenLayers

I have used a WPS process gs:UnionFeatureCollection to compute the geographical union of two collections of WFS vector features. The process returns a collection of features which I intend to display ...
2
votes
1answer
29 views

OpenLayers - cannot set layer opacity

I have the following problem: by default, you can simply change the opacity of layer by writing for example: layer.setOpacity(0.3); But when I add it to my map SelectFeature controls, my layer is ...
0
votes
0answers
50 views

OpenLayers DrawFeature Vector parameters

"Dear all, in my map application I am using a Vector/DrawFeature approach like this: var refresh = new OpenLayers.Strategy.Refresh({force: true, active: true}); var proj = "EPSG:900913"; var ...
0
votes
0answers
38 views

OpenLayers.Layer.Vector and BBOX

i configured this on my client page var kmlLayer = new OpenLayers.Layer.Vector("KML" ,{ strategies: [new OpenLayers.Strategy.Fixed(), new OpenLayers.Strategy.BBOX()], protocol: new ...
1
vote
1answer
26 views

Load a vector only for a specific zoom

I have a map with 4-5 vectors. At the beginning, the loading of the web application is very very slow, but was fine before I've added a new one vector, which is used only for little zooms. Is it ...
1
vote
2answers
268 views

Openlayers: Get Start and End Points of Line Vector Features

I'm trying hard to get start and end of lines from a vector. The line vector is loaded from a kml-file. For now, I tried to iterate over features in the vector and grab the start point and put it in a ...
0
votes
1answer
74 views

get and change style property openlayers

i need to change the property of some style after its created, and i need to change it with knowing only the string of the property name. i am getting string like "fillColor" and value like "blue", ...
0
votes
1answer
43 views

Select all features close to clicked

I have an openlayers map with more then 20000 features not in wms, only in vector layer. I have a control to select features, but sometimes it's really hard to select, specially the lines, and also ...
0
votes
0answers
49 views

how to easily serve vector layer with extra attributes for openlayers

On a website I'd like to show an openstreetmap with buildings colored by a certain feature (tag). So far I was able to extract the buildings for a bounding box, save them as an osm file and load it ...
1
vote
1answer
137 views

CartoDB map in openlayers

Is there a way that i can upload my CartoDB map in Openlayers as a WMS layer or Vector layer. Here is the my CartoDB map link. http://cdb.io/1nxdrpf
0
votes
0answers
71 views

How to achieve labeling in openlayers as Google did?

I am tried to find a solution for my question. Please look the images below. Google Google are awesome!!.. They are doing fantastic technique in labeling part. Please look the marked labels, the ...
1
vote
1answer
115 views

How to automatically transform between base layer and vector layer in OpenLayers

I have a simple example on http://jsfiddle.net/29bsw/ I have a map with an OSM layer as base layer and an additional vector layer. The projection of the map is defined as EPSG:900913 and the ...
0
votes
1answer
115 views

Geomedia WebMap WFS to vector marker layer in Openlayers

Looking for minimal example/advice on getting a WFS service to show up as a vector layer with markers/icons in Openlayers map. I have created the WFS service in Geomedia WebMap 6.01.11.19 and the ...
1
vote
3answers
143 views

How to prepare a multi-colored vector layer?

I need to present a multi-colored vector layer and something similar to below: I need to prepare the vector layer by making use with the data set available in my database. Inside my database, I ...
2
votes
1answer
92 views

Handle a great amount of Markers with OpenLayers

My general Problem is to maintain a lot of markers. For the beginning I want to display all Bus Stops of Berlin, Germany and surroundings as Markers. I already got that I have to use a strategy like ...
1
vote
1answer
66 views

cannot click on points in openlayers

I use openlayers 2.13.1 along with Geoserver and PostgreSQL I have a code for a vector layer , in my openlayers like so //style for layer var style_d = new OpenLayers.Style({ 'fillColor': ...
0
votes
1answer
454 views

Draw order (zIndex) of OpenLayers polygons and points in the same layer

My question is similar but slightly different from this one: http://stackoverflow.com/questions/5003349/openlayers-vector-features-z-indexing I have an OpenLayers Vector layer which contains polygons ...
1
vote
0answers
261 views

Updated: Openlayers Vector Layers with Google Map Base Layer (via Grid): Vectors Stick but can't get correct resolution/projection

Revamping this question instead of opening a new one. Previous issue: vector layers were not "sticking" to the map, so when you would zoom in or out the vector layers would "come out" at you. Note ...
3
votes
1answer
323 views

Openlayers vector layer don't draw well on chrome (single tile)

I have singleTiled layer in OL (using chrome). The layer don't draw completely unless I pan the map slowly to the south (here is example how the layer keep drawing itself each time I pan) : ...
1
vote
1answer
89 views

OpenLayers, Get clustered point's val

I'm working on a map with WMS overlays and a lot of markers, my problem is when I try to calculate the average of points clustered, I've found how to differentiate the behaviour and the label text ...
2
votes
1answer
2k views

OpenLayers Vector Layers: adding and removing features VS. redraw/refresh

I am currently using addFeatures and removeAllFeatures in my code to get the desired results and this is working OK. However, I have been asked to ensure that the vector layers are not being ...
0
votes
2answers
341 views

How to Resolve Inconsistent OpenLayers vector position Over Google map [duplicate]

I have an OpenLayers map with a Google base layer and an OpenLayers vector layer on which people can draw their own bounding boxes using the DrawFeature control. I have found that, as you zoom in, ...
1
vote
1answer
136 views

Openlayers Vector Event Popup with Textbox

The Openlayers map here: http://www.dassh.ac.uk/demonstrations/valmer/demo5.html has an event to add a vector layer, plus creates a textbox on the page below. Ideally I'd like the click event to add ...
-1
votes
1answer
695 views

Retrive data from database in openlayer GIS

i am using this code but it shows nothing, whats wrong with this code. <!DOCTYPE html> <html lang='en'> <?php $conn_string = "host=localhost dbname=postgis_21 user=postgres ...
1
vote
1answer
270 views

Openlayers Vector Layers eventListeners: how to specify different data without defining multiple layers

I have a map. It has two origins, and two destinations. The code for one origin is here: vectors_origin = new OpenLayers.Layer.Vector("Origin", { eventListeners:{ ...
7
votes
3answers
384 views

Create interactive map with no server

I have managed to build a great web mapping application using tiles created from GeoWebCache and a custom gridset, but I now need to add an overlay to the base maps. The only interactivity I need is a ...
1
vote
1answer
77 views

map can only have one feature, after user click

I'm using openLayers 2.13.1. I have a map wih a vector layer and Editing tools. I want the map to have only one feature even if the user keeps adding. So I want the new feature to automatically ...
7
votes
2answers
406 views

What does vector tiled map mean?

I'm working on an application that renders geoJSON into OpenLayers map. The idea is about not having PNG images downloaded from external services (OSM or Bing) but having geo information in geoJSON ...
1
vote
1answer
370 views

Check if feature is selected (Openlayers)

I wonder if there is a way to check whether a pointfeature (OpenLayers.Feature.Vector) is selected. I read the API, but didn't find any solution. Any idea?
1
vote
0answers
94 views

OpenLayers - Features in cloned layer changes style with original feature

Please help! My situation is that, I clone() a "newLayer" from an "oldLayer" with its features. Both of them seems correct at first. But then when I tried to change the style of "featureA" in the ...
1
vote
2answers
381 views

OpenLayers: WMS layer above select-controlled vector layer?

Is it possible to display an image layer (WMS or Image) above a vector layer with activated SelectFeature control in OpenLayers? The image layer (radar returns) contains only sparse, semi-transparent ...
1
vote
2answers
635 views

OpenLayers vector does not draw (or re-draw) on zoom level change or layerswitcher off/on

Here is the full code (i'll highlight the important parts after): jQuery(document).ready(function($) { // ...
3
votes
0answers
139 views

Cross-browser marker animation in OpenLayers

Currently I'm trying to implement animated markers in OpenLayers. I'm using PNGs for the markers, set by the externalGraphic style property on an OpenLayers.Layer.Vector. I need to be able to make ...
0
votes
1answer
653 views

provide an alternative “label” when styling vector layer with openlayers

I'm using openlayers 2.12 and I am styling a vector layer using your typical new OpenLayers.Style({ Now, this layer does two things. First , renders polygons from Geoserver, so in the style I have ...
1
vote
2answers
321 views

Custom filters (server side) for Openlayers Vector Layer

I have a vector layer in openlayers with source in GEOJSON (custom php server, which I have in complete control) and BBOX strategy. Vector points contain point sources which have different ...
0
votes
1answer
134 views

OpenLayers Strategies

Can we use the strategies OpenLayers.Strategy.Fixed and OpenLayers.Strategy.BBOX simulataneously on same vector layer?
1
vote
0answers
46 views

Align OpenLayer raster with OS Mapping Vector

I have an OS Vector map of a town in Ireland. When I load the Google Satellite Raster from the Open Layers plugin, the results are slightly off, by about 2m, probably due to ariel persepective. I'm ...
1
vote
1answer
331 views

Add a popup to a Vector LineString in OpenLayers?

Is it possible to add a popup (without a marker icon) to a Vector (LineString)? This is my code, if possible, how to change it to add the popup? I need the popup to display some additional ...
0
votes
1answer
107 views

show dwg,as background not as vector

I have some dwg files that i need to show as background on my map, but the DWG is not need to be vector layers, i need only to show them with out the need of using. if i am trying to convert it to ...
1
vote
0answers
61 views

Can I edit WMS layer or KML layer?

I am using Openlayers and until now i have been using OSM as background and i got points from my db (mySQL) and add them to vector layer, then i could modify them and save it back to the server. now i ...
0
votes
1answer
351 views

Selection problem in WMS layer using OpenLayers

I added 4 WMS layers (three polygons and one have point geometry) from GeoServer on my webpage My requirement is: I have to select a single polygon of one wms layer using a mouse click. After the ...
1
vote
4answers
3k views

Displaying a KML File on a Vector Layer in OpenLayers

This should be straight-forward, but I am beating my head over it. KML will not display. I have tried from same server and remote server to ensure it is not a cross-domain issue. The KML file loads ...
2
votes
0answers
255 views

OpenLayers Google v3 and other layers drift apart

I'm stuck. My code works with OSM, but I need it to work with Google as well. The problem is simply that Google v3 and my other layers are not playing well together at all. They don't zoom together. ...
0
votes
2answers
109 views

How to drag a point and then use savestrategy in OpenLayers

Im trying to use the wfs-t in openayers using the savestrategy. I have created a savestrategy and it works when I for example uses the DrawFeature Control to add a point. A new point is added to the ...