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

learn more… | top users | synonyms (1)

0
votes
1answer
151 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
19 views

Error Using 'L.mapbox.featureLayer' to load GeoJSON with pointToLayer Option

I am currently working on a project where I am loading GeoJSON into a map. The GeoJSON will include circles, point markers, and the other essentials shapes. I've been having this issue that I can't ...
0
votes
0answers
23 views

How to find the area of a feature in OpenStreetMap, using overpass api and javascript

I am creating a calculator and I would like to know the area of parks/water bodies in a specific area. This would have to be dynamic. I have successfully requested all the features I need using the ...
0
votes
1answer
45 views

Leaflet MarkerCluster custom info window instead of spiderfy effect

So I have been experimenting with the Leaflet Marker Cluster and was wondering if there is a way to disable the spiderfy animation and change the event when cluster is clicked on? Instead the clicking ...
0
votes
2answers
3k views

How to create styled markers with custom marker tooltip

How to create custom markers and when mouseover on marker i need a tooltip can any one suggest me how to do these type of markers...i need markers like below image Thanks in advance
1
vote
0answers
23 views

How can I access the array of predicted addresses from Google Maps once an address is entered?

The Google Maps JavaScript Autocomplete API mentions that autocomplete returns an array of prediction objects. How can I access this array without autocomplete? I have a standard HTML form with ...
0
votes
0answers
55 views

Leaflet: Scroll wheel controlling map zoom and not drop down menu

Edited 6/19/2015 I have a custom leaflet control box with a drop down menu. When I use the scroll wheel over the menu, the map changes zoom level instead of scrolling the menu. The problem occurs ...
0
votes
0answers
41 views

How can I get the mouseover event to work in my Leaflet.js map?

I have been trying to follow this mouseover example on the Leaflet.js website but I can't get my test version to work properly. The mouseover works only in some shapes at a time, but the mouseout ...
0
votes
1answer
171 views

Placing GeoServer WMS layer within OpenLayers 3

I have the following basic OpenLayers 3 code that opens a OSM background mapping and this works fine: <!doctype html> <html> <head> <title>Hello PMS</title> ...
1
vote
1answer
46 views

Arcgis Javascript Web Application: Workflow for Tokens?

This may appear to be a duplicate but I can't find any online source which is able to help me. Essentially, I want to protect a web Service from unauthorized access but still need to allow a web ...
3
votes
1answer
395 views

how to disable duplicate items in the legend for ArcGIS JavaScript API

I have a problem with duplicate items in the legend panel! Can anyone help me? This is my feature Layer with popup info: // Feature Layer var msFeatureLayer = new ...
0
votes
0answers
22 views

How to customize heatmap color on pre decided constraint values?

I am working on heatmap and situation is i have to change the color of heat map marker on the basis of some constraints and the color should change according to those basic constraints values. My ...
1
vote
1answer
220 views

ArcGIS javascript API setDefinitionExpression returns wrong result set

New to GIS and ArcGIS. I am trying to use the javascript API setDefinitionExpression to limit the output of a FeatureLayer on the map; however, the result set returned by the function is incorrect. ...
0
votes
1answer
184 views

How to submit data to modify feature using applyEdits of ArcGIS API for JavaScript?

I'm new to ArcGIS API. In a form, how can you submit data to modify a feature using applyEdits? No map is involved with this. I have a form that populates the editable data with javascript. When the ...
0
votes
1answer
203 views

OpenLayers 3 get map by id or class?

How can I get hold of a OpenLayers3 map object associated with a specific id or class (unique)? I searched and found this thread, which says something like: var map = ...
2
votes
1answer
417 views

How to write addressToLocations onError?

How can I write a code for checking the error condition in Javascript (ArcGIS) for addressToLocations(params, callback?, errback?). if somebody entered an invalid address- how can I call error ...
0
votes
1answer
20 views

Adding markers within constituency bounds using leafet.js and leaflet-pip

I'm trying to make a map where a user can select a constituency and then see a series of markers, from a much larger list, that are only within that constituency. I have the code below, and if you ...
2
votes
1answer
987 views

Search Functionality using Cartodb API

I posted a similar question about this a month or so ago and I was still in early stages of researching the problem thus not to many results came from it .After some time and effort I have come close ...
1
vote
1answer
25 views

Bubbles in Kartograph.js

I am trying to create the bubbles on my SVG map generated by Kartograph. I want to do something like this: http://kartograph.org/showcase/symbols/ The map loads but the symbol does not display. I ...
1
vote
1answer
163 views

Google Hybrid Map tiles won't load in OpenLayers when centered on certain position

Since the Google Maps API update to V3.2 (17 Feb 2015) our maps have not been loading to their initial state, centered over the Gulf of Mexico. When the center location is: center: new ...
2
votes
1answer
474 views

Leaflet setView with non lat/long CRS

Is it possible to use setView when using an alternative CRS? var map = L.map('map',{crs: L.CRS.EPSG26915}).setView([4970081,477018], 13); // Returns: Uncaught TypeError: Cannot call method ...
1
vote
2answers
1k 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($) { // ...
0
votes
1answer
23 views

How can I make a map-marker's popupContent be a random phrase?

I'm using leaflet.js to make a map and I need help with the javascript required to make a map-marker generate a random phrase with each click. I've used this code to generate random text: function ...
0
votes
1answer
83 views

Loading GeoJSON data into an array with OpenLayers 3?

First off I'm using OL 3.6 with no additional plugins. Pretty simple question that I thought would have been asked already/would have been much more readily available, is there a way to store points ...
0
votes
1answer
260 views

Geocortex Viewer: Running a Workflow with Arguments

I have a webpage with the Silverlight Geocortex Viewer embedded in it. Through the browser's developer console, I can run commands through it such as ...
1
vote
2answers
54 views

Configure default styles in LeafletJS

I want to change the default styles for vector layers in my Leaflet version 0.7.3. I can't find anything about that in in the documentation, so I made this hack: map.on('layeradd', function(e){ ...
0
votes
1answer
1k views

OpenLayers create marker (feature with icon) from WKT

I have a point object WKT. Like this: POINT (25.04568 48.221548). Also I have an icon in my project folder. My goal is to show on a map an icon that represents a feature. Can it be just a normal ...
0
votes
0answers
41 views

browser crashes when loading legends at startup

After much perusing for solutions, I've decided to post my problem as a question. I'm trying to load the legends that are built into the ArcGIS Service Layers I'm using. I'm loading about 7 Dynamic ...
1
vote
1answer
22 views

Simple popup for multiple WMS

I have multiple WMS in openlayers with a layer switcher and can be turned on and off. Now i have an image of each WMS, what i want is to show image of each WMS on click OF that corresponding WMS. ...
2
votes
0answers
162 views

Leaflet - Enable/Remove popup on mousedown/mouseup?

I'd like to do as the title suggests and can get the popup to appear on mousedown with the following code, but mouseup doesn't close the popup: // Quick look at info on mouse hold ...
0
votes
1answer
62 views

Openlayers 3 Cluster Strategy not projecting properly

As the title suggests, my Openlayers map is not displaying clustered points properly and I'm not sure why. My code is pretty simple and straight forward, here it is: JSfiddle: http:// ...
2
votes
1answer
332 views

Openlayers map WMS stretched by latitude

I am working on a small javascript application for displaying map with WMS layers from 2 servers. The problem is, that image is stretched by latitude, it is wider, as it should be. This is is how it ...
3
votes
1answer
74 views

How to create an exact tracking route from GPS data with animated icon?

Probably this is not purely GIS related question, its related to developing issues. I am just asking if there is any kind of suggestions from Gurus. I am building an tracking application where GPS ...
1
vote
1answer
13k views

Uncaught SyntaxError: Unexpected token : when using ajax

I try to call json data from geoserver, but when i try to run it in chrome, it return this following error "Uncaught SyntaxError: Unexpected token :" This is my code, function ...
1
vote
1answer
312 views

Using sql SELECT DISTINCT in Fusion Tables API

How do I go about using sql SELECT DISTINCT in fusion tables API?
0
votes
1answer
58 views

OpenLayers 3 how to keep original image extent

I'm new at ol3, I'm trying to display my GIS view by updating my ol2 code. I created the projection and I can display my static image but I'm obliged to use local extent [0, 0, 1024, 968] instead of ...
0
votes
1answer
49 views

How to call a leaflet Javascript Function in dropdown menu bar?

i have the following problem: my target is a hybrid app with leaflet. I create a dropdown menu with html/CSS/JQuery. Here is the code: <nav> <ul> <li id="menuPoint1"><image ...
0
votes
0answers
94 views

Open Layers 3 Zoom to extent only working in debug

Im using gpx data to display routes with open layers 3 and my attempts of zooming to fit the gps trace have been thus far unsuccessful. I only ever got it working in debug mode on firefox, where it ...
0
votes
0answers
25 views

Is there a way to measure height & width on extruded geometry (like 3D buildings) in Google Earth Plugin API?

Is there a way in Google Earth Plugin API to measure the heights & widths say for example between two clicked points on an extruded geometry of a 3D building over Google Earth Plugin? Something ...
0
votes
1answer
54 views

How to prevent Leaflet from loading tiles from server

I am currently developing a couple of solutions with LeafletJS and it frustrates me that my Firefox browser loads the tiles from the server (e.g. Stamen or OSM) and not from cache every time I reload ...
2
votes
3answers
2k views

ESRI proxy page not working properly + CORS + cross domain scripting

I have set up a proxy page. I am using jsp version of proxy page. I have set up a server URL which will point to my Java. When I load the my page which the proxy URL has set in its html it will work ...
0
votes
0answers
19 views

Geocoder Rest API different results than ArcGIS Locator separator?

In our JavaScript API we use a Geocoder to find buildings and rooms on our campus. So we created a own locator, which can find room numbers, room names, types of rooms and buildings. In ArcMap the ...
5
votes
1answer
2k views

Layer loadstart & loadend events in OpenLayers 3

OpenLayers 2 has these layer events "loadstart & loadend." What is equivalent to them in OpenLayers 3? While a vector layer loads and is rendered, I need to show a loading icon.
2
votes
1answer
484 views

How to get data from TileMill tileLayer properties in Mapbox for click/hover

I've successfully used Leaflet to load a geoJSON polygon-shapefile with data, and added click and hover interactivity to the layer. For a large dataset, I switched to mapbox.js 1.6.1, used TileMill to ...
0
votes
1answer
40 views

OpenLayers-3 setting zoom so layers fit in map window

Is there a way to dynamically set the zoom level so that the current layers always fit within the width of the map frame on page load? Currently the zoom level is set statically such that when using ...
0
votes
1answer
270 views

How to add WMS Layer from Mapserver( localhost) on Cesium Globe?

I am trying to add WMS layer from mapserver i.e. from localhost on Cesium Globe with the following HTML code. But I am not able to load or connect Cesium with the Mapserver and nothing is displayed on ...
0
votes
1answer
98 views

How to convert x,y to longitude, latitude in Cesium?

Actually I have divided a line into 90 parts. I know the longitudes and latitudes of end points, and for rest of the intermediate points I know x and y. I have to find height for those 90 points and ...
1
vote
1answer
211 views

Why do I have to reload the page, to show the Map correctly?

I added a map, in the way I'm supposed to, but why do I have to reload/refresh the page, to get the map (almost) as I want to? This is, what I mean: Map before reloading the page: Map after ...
1
vote
1answer
48 views

How to add href to popup (infoWindow) in ArcGIS API?

I'm a newbie in programming. I'm trying to make a href link inside of arcGIS js infoWindow (popup). I don't know how to make this link work. The code that I'm trying is shown below. Could you please ...
1
vote
1answer
32 views

Using auto-completion/code-completion in OpenLayers 3?

I wonder how I can make use of code-completion with ol3? In debugging-tools like firebug I can use the completion but I haven't figured out how to use the completion in an IDE. ( for OpenLayers2 it ...