JavaScript is a prototype-based, object-oriented scripting language that is dynamic, weakly typed and has first-class functions.

learn more… | top users | synonyms

2
votes
1answer
1k views

how to get Coodinates after Resizing a feature Openlayers

I'm trying to display the coordinates of a Feature or vector layer after I use the modify radio button to resize my vector, but it does not work, nor on my drag feature. I'm using ...
1
vote
1answer
1k views

How to stop or deactivate draw polygon control after the first polygon has been drawn in Openlayers

I want to only be able to draw one circle on my map and then disable the control. Below is my code, Any suggestions? <html xmlns="http://www.w3.org/1999/xhtml"> <head> ...
4
votes
1answer
2k views

How to draw Geodesic lines in Openlayers?

Hi i want to display multiple lines between two coordinates. i will pass no of lines and color of the line, it has to display like below image. please see the below image.this is my previous post
1
vote
1answer
2k views

Resizing and Reshaping features in Openlayers

Resizing and Reshaping features in Openlayers. I have a map with Openlayers and some controls to draw and modify Features. I need to activate the Resize and Drag and Rotate check button fields as ...
2
votes
2answers
2k views

Javascript Api's ArcGISTiledMapServiceLayer won't show map

I am currently trying to show a map that has been tiled. I am using version 10 of the arcgis server, and version 2.5 of the javascript api, the odd thing i am running into is that the map will not ...
1
vote
2answers
3k views

How to initialize a WFS Layer?

Here is the code block (the layers are stored in Oracle database): var saveStrategy = new OpenLayers.Strategy.Save(); var adresspt_wfs = new OpenLayers.Layer.Vector("Address points WFS", ...
2
votes
1answer
914 views

How to unproject coordinates on a Google map with Openlayers?

Below is my code and a pic. When I finish making my circle on a Google map with Openlayers, I get the following coordinates but I want coordinates like E.G: bottom: -27.762124575762 left: ...
1
vote
0answers
203 views

Avoid backtracking while creating loop in Google Map API 3

I am trying to build a solution where i would create loop by google map. My first and only business rule is there should not be any repeated route. But with my demo ...
2
votes
4answers
6k views

How to use Google Maps V3 Geocode with Openlayers

How to use Google Maps V3 Geocode with Openlayers. Below is my code but the function does not execute when I try to integrate it with Openlayers. This works with my original google v3 file. Below is 2 ...
7
votes
1answer
3k views

How to style features created by DrawFeature control?

I've been following this tutorial: http://workshop.pgrouting.org/chapters/geoext_client.html#select-the-start-and-final-destination It contains an Openlayers.Control.DrawFeatures control defined in ...
0
votes
1answer
626 views

How do you convert the radius decimals of a circle in Openlayers to Kilometers [duplicate]

Possible Duplicate: Unproject Radius with Openlayers with CRS:84 Projection I allow a user to draw a circle in Openlayers. I created an alert to show the radius of the circle. I now need ...
2
votes
1answer
2k views

How to get the radius of a “circle” in Openlayers

How do you get the radius of a circle in openlayers? I have searched quite a bit and cannot find any resource for this. please help. Here is my code but I want the radius or circumference of the ...
1
vote
2answers
5k views

Sending xml post request to geoserver

This may be simple question but I can't get started. This tutorial from pen state university has xml request <wfs:GetFeature service="WFS" version="1.0.0" outputFormat="GML2" – we would like ...
3
votes
1answer
6k views

How to Zoom to a FeatureLayer Using ArcGIS Javascript API

I am making a web application using the Javascript API and am trying to zoom to a feature layer from a row click in a dojo data grid. I have this working for a dynamic layer, but am having issues with ...
2
votes
1answer
1k views

How to Edit Popup using Openlayers Text Layer?

I am creating a map with about 1000+ points using Openlayers. Currently when I click on one point's icon, the description for the point shows up in a popup, and to exit the popup I need to click on ...
1
vote
0answers
325 views

Retrieve tile path of superoverlay in Google Earth Plugin using Javascript

I've created a superoverlay using MapTiler and am displaying that in a webpage with the Google Earth plugin. I'd like to identify the current tile (level, x, y) being displayed with a mousemove ...
1
vote
1answer
808 views

Capturing/overriding mousewheel zoom in openlayers

So I've created a map in openlayers and I am setting it up so that there are only certain zoom levels a user can see. I have the code created to handle forcing a user to the next acceptable zoom ...
2
votes
1answer
3k views

How to use Google Default Pan/Zoom controls in openlayers

I am using Google maps version 3 with Openlayers,My question is how do you use the default google control for Panning and Zooming and not the default controls Openlayers panning and zooming(The dark ...
0
votes
1answer
2k views

How to change events in the Oncomplete Drag function in Openlayers

below is code that works for Openlayers drag function: drag = new OpenLayers.Control.DragFeature(polygonLayer, { autoActivate: true, onComplete: function() {alert('Are you sure this is the ...
0
votes
2answers
9k views

Openlayers How would i get a hover label over my polygon

make a hover/mouseover label for a polygon in Openlayers? I made a map with draw, delete and drag polygon function. Now I need to make a hover mouseover for this. How to get a hover label for ...
0
votes
2answers
4k views

How to delete polygon in Openlayers

I would like to delete my polygon in Openlayers after i have drawn it. <html xmlns="http://www.w3.org/1999/xhtml"> <head> <style type="text/css"> html, body, #map { ...
2
votes
3answers
2k views

Openlayers get coordinates from polygon

please could someone help me and bless me with an example of how to get coordinates from a polygon in OpenLayers?
1
vote
1answer
3k views

Openlayers get coordinates of a circle vector after draw

I have made a openlayers map. I have made two features on the map. Navigate DRAW POLYGON I have made 40 sides to my polygon which turns out to be a circle. After I have drawn my circle I want to ...
1
vote
1answer
2k views

Loading a raster using Openlayers and Mapserver

I'm trying to load a raster into my browser using Openlayers. I can examine my WMS raster layer using OpenJump, but I'm not able to get it to load into my browser. My mapfile is as follows: MAP ...
0
votes
3answers
5k views

Understanding the polygon handler function in Openlayers

Using openlayers, I want to be able to draw one polygon on a map. After one polygon is drawn, I want an event to fire that stops any more from being drawn until a button is pressed. My current code ...
13
votes
4answers
3k views

Which framework is best to implement an application robustly, using ArcGIS Server JS API?

Over on the Esri forum, user Matt Moyles suggested that the approach used in the Esri JS samples isn't suitable for robust development of a web mapping application using HTML, JavaScript and CSS: ...
4
votes
3answers
3k views

How do I determine the center point of several features in OpenLayers?

I have several polygons being drawn on a map, usually representing a country or province or state. Depending on some chosen data, different regions may be selected, so what I was hoping is that ...
3
votes
1answer
710 views

How do I fire a function after all features have been selected by a box in OpenLayers?

I have a map rendering with Polygons on a Vector layer set up as features. I set up the features so they fire off a function when the feature is selected and this works fine. The issue I'm having is ...
6
votes
3answers
8k views

Creating a Bing and Google Tile Layer for Leaflet

I want to use the Leaflet Javascript Library to display both a Google and Bing Tile Layer, though I'm unsure how to construct the url. The documentation shows an example using OSM: var cloudmadeUrl = ...
1
vote
2answers
4k views

SelectFeature not working in OpenLayers

I'm still sort of new to openlayers, but I've been able to set up a map which reads in a KML, loops through the different regions contained therein, and draws those polygons on a vector layer overtop ...
12
votes
2answers
5k views

OpenLayers alternatives supporting more client-side features

I am considering different architectures for a system that will ideally use client-side rendering for point features and must be plugin-free. I have been using this application developed in response ...
0
votes
1answer
654 views

Purely client-side geocoding options for a webmap

I am creating a simple webmap that should be able to: Display external maptiles (any of the following: Cloudmade, Mapquest, Google). Overlay additional static layer in Geojson or KML format, that ...
2
votes
5answers
3k views

Event listeners after each plotting of a point of a Polygon Vector in OpenLayers

I am quite new to OpenLayers. I have a polygonLayer for users to draw polygon vectors. The plotting feature is working fine. polygonLayer = new OpenLayers.Layer.Vector("Polygon Layer"); ...
8
votes
3answers
2k views

Mobile offline mapping and editing of shapefiles

I've got a client that wants to create a mobile app that can view and edit shapefiles stored locally on the device to enable it to work offline. There is a possibility of converting the shapefiles to ...
2
votes
1answer
664 views

ESRI - Polyline insertPoint issue (JS 2.5 API)

I am trying to basically draw a path on an esri map. with circles like so, but when I call Polyline.insertPoint it doesn't show the new segment: I keep adding points as time progresses. My ...
1
vote
2answers
762 views

How to create a custom Balloon for Google Earth?

I just came across one question related to google maps in stackoverflow. Google Maps: How to create a custom InfoWindow? I really like the popup that they mentioned in the question and the image is ...
2
votes
5answers
8k views

Why is this ExtJS combo box not filtering? [closed]

I am trying to place a combo-box in the top of my web application which will search an internal WFS from Geoserver. I am using the combo-box so I can have the "type ahead" functionality which I think ...
11
votes
3answers
2k views

Where can I find country borders data in human-readable format?

I'm trying to obtain some data representing the borders of all countries in the world. This data doesn't have to be very precise, it is to draw the countries on a computer screen. I did a bit of ...
5
votes
1answer
4k views

How to create a movable point in OpenLayers?

I have the following code: function mapCreate(lon,lat){ map = new OpenLayers.Map("map1"); var osm = new OpenLayers.Layer.OSM(); vectors = new OpenLayers.Layer.Vector("Vector Layer"); ...
9
votes
2answers
2k views

How to add a layer to SelectFeature without losing existing selections?

I'm using an OpenLayers.Control.SelectFeature for selections on multiple layers. However, when I add a layer using setLayer(), my selections on the other layers are lost. Anyone know how to work ...
14
votes
8answers
10k views

How to Create Animated Cluster Markers in OpenLayers/Leaflet?

I want to use Leaflet due to the smooth transitions which Openlayers seems like they can't match. I specifically require the ability to cluster markers with custom styled marker groups. The best ...
1
vote
4answers
1k views

Map in an iFrame - open hyperlink from infoWindow in the calling page

I've got a Google Map being served inside an iFrame on a page (eg xxx.com/PageWithMap.html) The code for the Google map sits on another domain (eg yyy.com/MapCode.html) So it looks like this on ...
0
votes
1answer
709 views

How to highlight track in KML on hover with OpenLayers

I have KML layer with multiple tracks and I would like to highlight them individually on mouse hover. I tried to implement this like in the example found in OpenLayers examples, but couldn't get it ...
5
votes
1answer
366 views

Why do ArcGIS Desktop 10 HTML popups give JavaScript/HTML Error?

Using ArcMap 10 Desktop HTML Popups. The issue I am having is that the html < select > elements aren't working - you can select it and use the arrow keys to navigate through(up/down) the list but ...
5
votes
2answers
639 views

How to time function calls in OpenLayers?

We have an existing application that has a function that wraps the OpenLayers.Layer.Vector constructor, which gets its layer info from a KML source over http. Once this function completes, I need to ...
2
votes
0answers
383 views

GeoPDF Library for .NET or JavaScript

Anyone know of any open source .NET or Javascript libraries for creating GeoPDFs? I know of QuickPDFLibrary, but i'm preferably looking for something open source. I want to programmatically generate ...
4
votes
1answer
2k views

Changing the line color of a marker box using OpenLayers

I'm trying to figure out how to change the line color of a marker box in openlayers. I've been learning from the following example: <!DOCTYPE html> <html> <head> <meta ...
4
votes
1answer
454 views

Why is my polyline on the wrong bearing?

I am trying to overlay duplicate segments of polylines on a map via javascript. I am using latlon.js and geo.js from here The idea is that a user can input the distance they have travelled and when ...
1
vote
1answer
991 views

Invalid filter when using MapServer as a WFS

I'm trying to use Openlayers and Mapserver to display a shapefile. My HTML file is as follows: <html> <head> <title>OpenLayers Example</title> <script ...
2
votes
2answers
194 views

Is there a GroupRenderer in ArcGIS for javaScript?

Is there a GroupRenderer or similar functionality in ArcGIS for JavaScript? What I would like to do is to show PictureMarkers with a label showing an attribute on the Graphics object.