OpenLayers is a JavaScript library for creating dynamic map widgets for web sites.

learn more… | top users | synonyms

1
vote
1answer
423 views

Markers not displayed in xhtml in OpenLayers

I just started working with OpenLayers because I want to include a map on my JSF page (.xhtml files). I want to use the same feature that is demonstrated in this example: ...
1
vote
2answers
494 views

Re-initializing OpenLayers Map with different projection

Is it possible to re-initialize OpenLayers Map with a different projection ? Scenario: OL Map with projection 4326 is created, along with click, measurement, drawing handlers. A button to switch to ...
2
votes
2answers
1k views

Highlight the WFS Layer on mouseover

I've set up a WFS layer in openlayer: var v1497_shp = new OpenLayers.Layer.Vector("v1497_shp", { strategies: [new OpenLayers.Strategy.BBOX(), saveStrategy], //projection: new ...
2
votes
1answer
1k views

Why doesn't OpenLayers zoom?

I've got a little problem with OpenLayers. I've a simple function which sets the center of the map to the position of the user - this works fine. But: it should also zoom - which, for an unknown ...
4
votes
1answer
4k views

Showing menu based on right click on Point Geometry in Javascript

I have implemented a vector layer(using javascript) in open layers which is having point geometry. Now my requirement is to show menu just besides with the point whenever we do right-click on ...
5
votes
3answers
3k views

Different level of detail(layers) on different zoom level at OpenLayers map

I want display different detail(layers) on different zoom level on OpenLayers map. I mean when zoom in should display lot of layers and when zoom out those unsuitable layers should hide automatically. ...
2
votes
4answers
4k views

How to do geo coding with openlayers?

How can I achieve Geocoding with the JavaScript OpenLayers API, in the same fashion as the Google Maps API?
1
vote
2answers
902 views

How to add pictures to OpenLayers map using GeoServer?

I have web map showing land parcel and buildings.I am using GeoServer WMS and OpenLayers. My buildings are showing as point on map.Then I want to add some images to those points to show when ...
2
votes
1answer
1k views

OpenLayers popup - random losing click event, have to refresh page

I have a OpenLayers, Mapfish, GeoServer map on a webpage. I am using OpenLayers.Popup and getFeaturesInfo to get the attributes from GeoServer (2.1.3). I have several wms layers with markers and ...
1
vote
1answer
2k views

Measuring on OpenLayers map

These days, I am trying to develop web map using openlayers. I copy source code from here Then I changed code to display my data.B ut it does not work, even map is also not showing. In chrome shows ...
1
vote
2answers
2k views

How to get vector feature information (distance and extent ) on OpenLayers

I have basic WMS layer and vector layer in openlayers. Using EditingToolbar i can draw some features as shown below Then I want to get some information (like distance and extent) of drawn features ...
1
vote
1answer
2k views

How to display pop up image when click point in open layer web map

I have basic WMS web map showing parcels and points layer which representing buildings of parcel.Then I want to add building images for each and every point. Then when a user clicks on a point image ...
2
votes
1answer
3k views

Trying to set the OpenLayers MouseOver position to be outside the Map

This is my code and I am trying to obtain the MouseOver to be displayed outside the Map container. <!DOCTYPE html> <html> <head> <title>My Map</title> ...
1
vote
1answer
186 views

Click Handler not working on OpenLayers Map in Ubuntu

This is really strange as the problem seems to be persisting on the Ubuntu OS itself. I have created a WMS and it works fine on Mac and Windows, but not on Ubuntu. I have a simple WMS which is ...
2
votes
1answer
185 views

Any source code for converting an infix filter to a WFS filter?

A WFS GetFeature query looks something like this: ...
2
votes
3answers
1k views

Openlayers: Copy shape layer in a vector layer

I have a web-gis application based on openlayers and geoserver. I need to modify a shape layer. I'm able to show the shape using the OpenLayers.Layer.WMS method. In fact i published the shape in ...
2
votes
1answer
433 views

How to add more than one xml file per layer

I'm using this code to add xml (osm relations) files to my map. osm_layer = new OpenLayers.Layer.GML("Polygon", relation.xml, { format: OpenLayers.Format.OSM, style: {strokeColor: "blue"}, ...
2
votes
4answers
1k views

creating 2 dragable layers at the same time in OpenLayers?

I have been been working with this for a while now. Whenever you add 2 seperate draggable layers, openlayers will only activate the last one added. I wish it could be as simple as the code below. But ...
2
votes
1answer
919 views

Open Layers Control Modification

function testPanZoom() { console.log("test func"); var newPanZoom = new OpenLayers.Control.PanZoom(); OpenLayers.Util.extend(newPanZoom, { onButtonClick: function(evt) { ...
7
votes
4answers
2k views

How to close watermarks window in QGIS Openlayers plugin?

I'm using Quantum GIS Ver. 1.7.4. I have upgraded openlayers plugin 0.7 to 0.9. However when I open google satellite, a watermarks/copyright dialog box "Data Peta@2012 ..." appear in the middle of the ...
2
votes
2answers
5k views

Openlayers - Zoom to selected feature

if I have this vector layer: var vectors = new OpenLayers.Layer.Vector("vector", {isBaseLayer: false}); var feature = new OpenLayers.Feature.Vector( OpenLayers.Geometry.fromWKT( ...
4
votes
4answers
4k views

How do I use base layer of two different projection Spherical Mercator and WGS84?

How do I add baselayer with two different projection? I have added overlayer with a different projection(EPSG:4326), but I need to add base layer with various projection Google Map My vector layer ...
1
vote
3answers
2k views

WMSGetFeatureInfo not showing in Firefox and chrome

This code set works for me in IE but not in Firefox and chrome.What is the problem? Map is showing in all browsers ,but when i click on point of map nothing showing in Firefox and chrome. Welcome ...
1
vote
2answers
630 views

Client Zoom in OpenLayers with Google layer

I'm displaying some features on a map, but the features are somewhat on the small side and can't be easily viewed at default zoom levels. Using the Client Zoom example, I was able to enable acceptable ...
1
vote
1answer
2k views

OpenLayers: Load Markers dynamically from Text file

I am trying to load set of markers dynamically from a text file using OpenLayers.Layer.Text. The problem is that no markers is shown after rendering the page. Below is the JavaScript file that is ...
4
votes
1answer
488 views

how do I get rid of that blue circle that is on the cursor when drawing a point in OpenLayers?

In openlayers, before placing a point, there is a small blue circle the moves with the cursor. I want to get rid of that and can't figure out how. If possible, it must be in the following section of ...
6
votes
4answers
3k views

WMS GetFeatureInfo and CQL on Multiple Layers

I am having issues with querying CQL filtered layers with OpenLayers and GeoServer, using the GetFeatureInfo control. It is ignoring the CQL filter and just querying the entire layer (as evidenced by ...
3
votes
2answers
1k views

Display two layers with OpenLayers at once

How can i display two layers with diferent projections at once? For example i have layer with EPSG:70076 and OSM layer.
1
vote
2answers
805 views

Set up the center of a map with Google Layer as basemap in OpenLayers and GeoExt?

I looked on similar questions but in vain. The map is working fine but has a center of (0,0) as returned in the Firebug console not (-8, 32) that I want. I did the projection transformation.. Here is ...
3
votes
1answer
1k views

How to prepare or normalize raw shape (.shp) files for Openlayers use

Hi all it seems like I am having difficulties in normalizing raw map files' resolutions to openlayer's use most probably in parameters mapext and imgext. I hope you can help me with this. Using raw ...
1
vote
2answers
858 views

Why should we use a proxy script for Apache, Geoserver, OpenLayers?

I can't understand why we use proxy( OpenLayers.ProxyHost)for WMSGetFeatureInfo request in open layer. I am using open layer 2.10 ,apache-tomcat-6.0.35 and geoserver. Why we use proxy? How should ...
3
votes
1answer
379 views

How to migrate a Geoserver setup to Tomcat?

I have some problems with tomcat/geoserver. I was create project in stand-alone geoserver and all works fine. This is my code. <%@ page language="java" contentType="text/html; charset=UTF-8" ...
1
vote
1answer
1k views

To get FeatureInfo in OpenLayers

I am new to OpenLayers and I want to add OpenLayers.Control.WMSGetFeatureInfo to get feature info to website.But i can't figure out right method. I also see the source code of GeoServer OpenLayers ...
1
vote
0answers
38 views

Reprojecting in OpenLayers [duplicate]

Possible Duplicate: How to reproject base layers in OpenLayers? I Am trying to reproject my map from epsg:4326 to epsg:900913 but I couldn't do it. here is my codes OpenLayers Example ...
0
votes
0answers
214 views

session id changing ; tomcat and apache web serevr

I'm using a WFS protocol on Vector layer. also I'm working on 2 servers, tomcat (to deploy GeoServer) and Apache web server(because i use php) I have an HTML page works on Tomcat and login.php and ...
10
votes
6answers
2k views

Should I use a CMS for my web mapping application?

For my web mapping app, I am using GeoServer as server, PostGIS as spatial DB and OpenLayers on client side (as well as other JS libraries). The map is composed of base maps and vector layers. One of ...
1
vote
1answer
337 views

Identify functionality using mapserver

I am just creating a simple web application using mapserver. It has the basic pan, zoom in/out functionality. Now what I want to try is to get an identify functional added into it so that when I click ...
1
vote
2answers
342 views

What components does OpenLayers.Strategy.BBOX require for compilation?

I recompiled OpenLayers with minimal settings, and now Vector layer, that uses BBOX strategy, stopped adding bbox parameter to the queries. What components do I need to add? This is the current ...
3
votes
2answers
1k views

Ovi Maps in OpenLayers?

Yahoo stopped their Yahoo! maps web services (link1 : We are shutting down this service on September 13, 2011. We suggest using maps from our partner Nokia. Please visit the Ovi Maps API for more ...
2
votes
1answer
954 views

Touch 'tap' event not available on openlayers 2.11 map (update: click works fine)

According to Will mousedown events fire with Touch events on OpenLayers mobile?, openlayers 2.11 supports click-like behaviour for vector layers only. Separate from that, regular ...
2
votes
1answer
3k views

Why does Geoserver WMS not work in OpenLayers?

I am relay new to webGIS and these days i trying to develop webmap using FOSS software. This is my codes of open layers and it is not working. Geoserver URL ...
1
vote
1answer
366 views

what format distanceTo function returns in OpenLayers?

i am using distanceTo function in OpenLayers Geometry. http://dev.openlayers.org/docs/files/OpenLayers/Geometry/Point-js.html#OpenLayers.Geometry.Point.distanceTo here am confused in which format it ...
3
votes
1answer
2k views

Openlayers zooming and panning restrictions don't work

Consider the following example (I tried to keep it as simple as possible). <html> <head> <style> #map { width: 800px; height: 600px; } </style> <script ...
4
votes
2answers
2k views

Prevent OpenLayers WMS layer cache by browser

I am using OpenLayers (GeoExt) with google chrome browser. All WMS layer is for live database. I have refreshed the browser at certain interval using javascript but the data is cached in browser and ...
6
votes
3answers
1k views

Determine if a polygon intersects itself in OpenLayers

I let the users draw polygons and then I try to save them out to the SQL Server 2008 SQLGeography field, but it is giving me an error: Error 24200: The specified input does not represent a valid ...
3
votes
1answer
919 views

printing openlayers map

What i've got is a map served by the tilecache and shown by openlayers and geoext. Now i need to print this map, so what i've done is: made a button which creates (window.open()) a new window with ...
2
votes
1answer
1k views

How to make a predetermined Polygon (Circle) From 4 Coordinates, The Radius and Center Longitude and Latitude in Openlayers

I know how to make a predetermined Polygon in Openlayers (see below). Please have a look at http://studio.netnrg.co.za/dev/rnd/blake.loizides/openlayers var feature2 = new ...
1
vote
1answer
63 views

Doubts about Manipulation of Layers

I'm working with OpenLayers, I created a new plugin to perform a selection feature. But every event I perform in my plugin button it creates a new layers. (Attached is a print). Of the attempts that ...
2
votes
2answers
1k views

OpenLayers GetFeatureInfo Error in Geoserver

I was advised in a previous post to ask this question again using a small data sample My base layer is a postgis vector dataset in WGS84 When I click on the map I get the following an error in the ...
1
vote
2answers
2k views

add location search to openlayers map

I am trying to figure out how to add a search functionality to my openlayers map. I want the user to type in an address and the map to zoom into the location. I am looking at different geocoders and ...