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
64 views

OpenLayers 3 custom control doesn't get the map object

I've been playing around with extending controls in OpenLayers 3. I've built a control which grabs a legend image from a mapserver with a GetLegendGraphics request. However, when I add the control to ...
0
votes
1answer
38 views

How check if a point is inside a map

I have a map and one point. I want create an area and check if a point is inside the area. map = new OpenLayers.Map("map"); map.addLayer(new OpenLayers.Layer.OSM()); var lonLat = new ...
1
vote
1answer
36 views

Function to intersect another polygon using openlayers

I wonder if someone here have a function JS that when I draw a polygon I can see if i drawing on another polygon, like intersect.... if polygon intersect say to me a alert...using openlayers. Thanks! ...
0
votes
3answers
90 views

Leaflet is behaving unexpectedly when trying to load more than one layer

I had a hard time trying to create a good title for my issue since it is a little hard to explain. But I will do my best. Basically what I'm trying to create a web map to show three distinct layers, ...
1
vote
1answer
31 views

Assign points with varying radii to central meeting locations

I have a set of points in a city, each with a maximum distance radius of 0.5 - 1.5 miles. From this set of points, I'd like to create a small number of 'meeting points', i.e. locations that are ...
1
vote
0answers
18 views

Disabling TextSymbol Scaling on Zoom in/out (ESRI JavaScript API)

I am looking for a way to disable text scaling when a user zooms in/out on a map with a TextSymbol on it. It this possible?
1
vote
1answer
37 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 ...
1
vote
0answers
22 views

JavaScript _.each function not showing correctly [closed]

Can't seem to get this to display the correct way. The correct way would be Day/open/hours. geojson displayed below: hours: { monday: { close: "18:00:00", open: "10:00:00", call: ...
1
vote
1answer
32 views

ESRI Javascript API pan parameters

Using the ESRI javasript API, is there a way to set the distance the map will move when panning? When I fire the map.panUp(), for example, it pans, but about twice as far as I would like it to.
1
vote
1answer
62 views

why are all polygons of geojson-layer in OpenLayers 3 black?

I want to color each polygon of my geojson according to its Hex-Value at "DN". I tried this: var map = new ol.Map({ target: 'map', layers: [ new ol.layer.Tile({ source: ...
0
votes
2answers
21 views

How to get Scale Bar, WebMap with GeoExt

I tried to make a WebMap with GeoExt and everything is working, but I don't see a scalebar. var mapPanel, tree; Ext.application({ name: 'test', launch: function() { ...
0
votes
1answer
11 views

Fetch the selected value from scale toolbar

can somebody guide me how to fetch that value shown in the image? using jquery and or PHP language?
0
votes
1answer
60 views

Which map API to draw polygon and export my data that is within boundary?

I have 5 point datasets that I want to display and be able to filter by fields. I will then be able to hand draw a polygon and export Excel of the data from each dataset within the polygon. Which web ...
1
vote
1answer
39 views

ArcGIS JS api - how to hide attributes editor when new graphic is added

I use ArcGIS Javascript api in 3.12 version. I have followed this sample in order to display editing toolbar plus template picker. It works pretty good. However I would like to hide popup window with ...
1
vote
1answer
162 views

Add GeoJSON layer to OpenLayers 3

I have a GeoJSON file called mygeojson.json and I want to add it as a layer in OpenLayers 3 on top of an openstreetmap layer. So far I could display the openstreetmap world including zoom etc. but for ...
2
votes
1answer
57 views

How to project a GeoJSON on the fly in OpenLayers 3?

I have been trying to load a GeoJSON without success. I have a map with a background layer from OSM. I have some data in 4326 I want to overlay on that map. I do not want to transform coordinates one ...
1
vote
1answer
22 views

A problem with event firing upon mouseout

I'm trying to create a point map that displays information about a point in an info box upon user mouseover and changes the styling of the point. On mouseout, I want the info box and marker styling to ...
0
votes
1answer
31 views

Download zip from geoserver using javascript

How can i download zip file, made by geoserver WFS request, implemented in javascript? i'm using OpenLayers.Request.POST to send request.
0
votes
2answers
33 views

CartoDB, Torque map sending events to JS when a market is rendered

I have a Torque map like this one and at the same time the bubbles are showing up I would like to render a growing graph with the number of bubbles accumulated. I don't expect CartoDB to do this for ...
0
votes
0answers
18 views

Rotated custom tile set in OpenLayers

I'm thinking of using Openlayers for an interactive map of a building. I'll have custom tile layers for each floor of the building's interior overlaying regular world map tiles. The building is on a ...
0
votes
1answer
240 views

display latitude and longitude on googlemaps on click

iam trying to retrieve latitude and longitude values .when user clicks on the google map latitude and longitude values has to be displayed on the textboxes my code is <%@ Page Language="C#" ...
0
votes
0answers
36 views

How to create function that gives google maps getBounds result?

I'm trying to create function that would calculate four bounding coordinates by latLng, zoom level, width and height in pixels, the same like in google maps getBounds function, in goal I won't create ...
0
votes
0answers
31 views

Attributes and Zoom

I have loaded shapefiles on OpenGeo Suite template (ol3view), I'd like to create a popup on click for each point to show attributes. I'd also want to highlight a certain part of the map perhaps by ...
1
vote
1answer
31 views

How do I catch PostgreSQL/ PostGIS RAISE messages in OpenLayers?

Is it possible to catch Raise Warning, Raise Notice and Raise Exception in OpenLayers while using a WFS-T-Layer (stored in a PostGIS-Database) to save edits? Example: A trigger is used to check values ...
2
votes
1answer
67 views

Loading Simple ESRI html JavaScript in Internet Explorer 11?

Is there any particular reason this Simple ESRI html javascript wont load in IE11? Chrome works fine <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" ...
0
votes
0answers
25 views

Configurable map viewer (CMV) - Help dialog

I have the help widget set to open on start. I was wondering if there was a way to have the help widget display one tab on start and another when the help button is clicked?
1
vote
1answer
121 views

Arcgis Javascript API Editor Widget gives a different result when loading through AMD

Currently i'm working on a Arcgis based drawing tool. What we've done so far is create a system where we can easily create local feauture layers and edit those with the standard Editor Widget. Drawing ...
0
votes
1answer
33 views

Best Map API for route polygon calculations

We are building a web app. I need to obtain the area reachable from specific points by driving or by walking in order to obtain the polygon (eg., 5 minutes walking polygon from a specific point), so ...
1
vote
1answer
40 views

Running ArcGIS API for JavaScript locally?

I'm pretty new to arcgis javascript api, and I'm wondering how to run it locally. I have downloaded the api, and put the folder "arcgis_js_api" in the root folder of my apachi server, and edited the ...
0
votes
1answer
16 views

custom button in OpenLayers

I am trying to use a custom button in Openlayers but is does not work. what am i doing wrong? var custom_button = new Openlayers.Control.Button({ displayClass: 'olControlCustomButton', ...
0
votes
0answers
21 views

CartoDB - infowindow / templates - multiple languages

Is it possible to configure CartoDB infowindow and templates in different languages via visualization panel? For instance, I am thinking to define in client js viewer some language templates, detect ...
0
votes
1answer
42 views

CartoDB - panel info instead of infowindow

I am using CartoDB API to develop a map viewer and I would like to get the information from featureClick into a content panel instead of the typical infowindow. Is there any method to do it directly? ...
0
votes
0answers
44 views

How to change cursor to pointer mode while Dragging & Dropping in OpenLayers 3?

How to edit the cursor to pointer mode while using the ol.interaction.DragAndDrop in OpenLayers 3?
0
votes
2answers
46 views

How to show which layers are currently visible

I feel like this is a rather easy one, I just cant get it to work... Basically, I want to show which layers are visible from a dynamic layer. I see all the objects being returned in the console with ...
0
votes
0answers
15 views

leaflet filelayer.js change click event

First off, I am no Javascript expert. Second, I have a feeling this is nice and simple for someone with skills. I am building a map and incorporating the leafletfilelayer plugin. The plugin works ...
0
votes
0answers
56 views

Problem hosting web map template in local web server

This is the Webmap I have prepared in ArcGIS online. http://www.arcgis.com/apps/Viewer/index.html?appid=c72a0fc5e554462daec7df89bcc3adf4 I have downloaded a sample template from ...
0
votes
2answers
39 views

Use try, catch when querytask times out using JS API

When I do a querytask and the date range criteria used is too vast, I get a 500 internal server error after 1.7 minutes every time (unless the query takes less than 1.7 minutes, then it runs fine). Is ...
0
votes
1answer
123 views

Stop OpenLayers 3 map firing click event after dragging

I have an OpenLayers 3 map with a source of ol.source.MapQuest({ layer: 'osm' }). I haven't added a DragPan interaction, but the map is draggable anyway - which I want it to be. I also have a click ...
0
votes
1answer
27 views

Hash of Feature Layer Graphics

On a web application I'm currently working on, some of the data for the GIS Service is bad. For instance, there may be multiple polygons that should be a singular graphic, but instead they are each ...
0
votes
1answer
57 views

Displaying more than one layer from GeoServer using OpenLayers?

How can I add additional data layers to this code? I tried using "map = new OpenLayers.Map('map', options);" again and set up a tiled layer for buildings exactly as it has been done for roads but not ...
0
votes
0answers
47 views

Connection to Shapefiles and PostGIS

I have this HTML (see below) code, I want to connect to PostGIS to the Shapefiles I have loaded, but I can't find where and how to accomplish that. I want my map to display this Shapefiles when the ...
0
votes
1answer
42 views

Does an event get fired after a Layer has finished rendering in Openlayers 3?

I am rendering about 27000 Markers in different layers on a mapview. Everything works fine on fast devices. I have a problem on older devices (like the iPad3). When i hide one layer and set another ...
1
vote
1answer
37 views

How to toggle selected features by clicking on them in OpenLayers?

This is my website for test: http://www.cv.nctu.edu.tw/shapefile-js-openlayers/ol_simple.html This is my expected result:http://www.cv.nctu.edu.tw/shapefile-js-openlayers/test.html I want to try ...
1
vote
1answer
42 views

OpenLayers map with Nominatim lookup function not working

I am trying to create a simple map with a search function, my minimal example is here: http://jsfiddle.net/TimLucas/vbaupe30/4/ For some reason the coords transformation after the script has received ...
2
votes
1answer
84 views

Why my Shapefile is not loaded into OpenLayers?

This is my website for test: http://www.cv.nctu.edu.tw/tonywang/shapefile-js-openlayers/ol_simple.html I want to put my Shapefile in OpenLayers. I found an example at ...
3
votes
1answer
47 views

Define a circle extent using the circle tool - arcgis javascript api

I have the following script for drawing a circle and I want to limit the user to a predefined radius: $('#circle').click(function () { clearPreviousSearch(); ...
1
vote
0answers
51 views

Limit Nominatim results tp specific country

I want to limit the search in Nominatim to a specific country and was trying this code: mapPanel = new GeoExt.MapPanel({ border: true, region: "center", map: map, zoom: 7, ...
0
votes
1answer
46 views

How to obtain elevation value from given SRTM data on mouse click in web browser?

I need JavaScript code for obtaining elevation data from SRTM tiff image. I have used Google APIs, but I need for downloaded SRTM tiff image. (SRTM file is being loaded on a base layer, and both ...
0
votes
0answers
32 views

Prevent rendering of a layer until time definition is applied

I want to add layers to a map, with some criteria. Before the layer is drawn, I want to a set a time definition on the client-side to limit the data being rendered. I've tried setting the time ...
1
vote
1answer
68 views

Programatically add feature to Feature Layer with ArcGIS JavaScript API

I've so far been able to add a feature layer from an ArcGIS server, and I've also been able to add an editor widget which allows me to draw to feature with the mouse. The added features are being ...