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
vote
2answers
226 views

How to convert Shapefile to TopoJSON with grouping neighbor shapes by some criteria

I have a shapefile with countries, which I convert to GeoJSON using ogr2ogr and then converting that json to another TopoJSON, using topojson command-line tool. Everything works like charm, but now I ...
1
vote
2answers
583 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
0answers
270 views

Help me convert this US Lambert Conformal Conic Google Maps Projection to Australia

Following on from this question: Identify what projection this Australian map uses? <- this is the sort of map i want to load in I need help changing the bits necessary in this example of Lambert ...
2
votes
2answers
534 views

Can I use leaflet to access a WMS service published as an OpenLayers javascript API?

I would like to add this layer to a site I'm working on that uses leaflet: http://116.240.195.134/vicmapapi/UserGuide.jsp The API itself is a javascript file based on OpenLayers: ...
2
votes
1answer
139 views

OpenLayers: Can I drag a feature between two maps?

Is it possible to drag the features between two different maps? Now, I create feature on event mouseenter but I would like to insert the feature and at the same time start to drag this feature.
0
votes
0answers
183 views

Dynamic CQL filter does not work

I'm using Openlayers 2.12 with Geoserver 2.1.3. I am implementing a dynamic CQL filter to search a vector layer. This is for the back-end of the web-site, so I want to restrict the search like so: ...
0
votes
0answers
56 views

Change feature's image when it's not clustered

I'm clustering the features on the layer using AnimatedCluster this way: dataLayer = new OpenLayers.Layer.Vector("Data", { strategies: [ new ...
0
votes
1answer
160 views

Issue selecting feature for IdentifyTask (Javascript API)

I am having an issue selecting features in my web map for an IdentifyTask operation. I have a dynamic map service that contains a few sublayers that I would like to be able to click and have a popup ...
1
vote
0answers
37 views

Are there any js libraries for reading OSH data?

I want to do time based mapping on openstreetmap data in the Kathmandu, Nepal area. I think i have two options Using OpenStreetMap Change files (OSC) Using OpenStreetmap History files (OSH) I have ...
3
votes
0answers
374 views

Using Custom Map Projection On Leaflet

I have an application displaying a EPSG:3414 map running on Openlayers - jsfiddle working sample that works. I am trying to implement the same on Leaflet - jsfiddle non-working, it is not working as ...
4
votes
2answers
423 views

LeafletJS: Load Tile Layer based on bounding box

I have a LeafletJS map application with lots of layers. I have a few layers that only have imagery for certain regions across the world. Because everything goes on a world base map. All tile caches ...
3
votes
2answers
647 views

Cluster Strategy different Labeling at Different Level

what I did? I am trying to plot some points using cluster strategy of openlayer using animatedCluster plugin. I have gson data as given: { "type": "FeatureCollection", "features": [ { ...
0
votes
1answer
64 views

Fusion table styling

I am importing data from fusion table data as a layer. but the colour i used in fusion tables is not reflected in my map. it by default remains red small icon. Please let me know if I am doing ...
3
votes
3answers
131 views

Is it necessary to use a third party service for serving this case?

I have been assigned a task to help build a mobile app, which only shows terrain view of map with a fixed (min/max) zoom level based on mobile phone position and moveable markers which are provided ...
3
votes
2answers
193 views

Are there any good libraries for visually creating simple Google Maps?

I'm working on a simple webapp that lets the journalists I work with easily construct styled Google maps. In short, I need an interface that lets users place markers, set zoomlevel and choose a ...
0
votes
1answer
94 views

Mouse click event used gis application with much data

I will create an application that using my water pipes, electric cables, gas pipes service in a city. All of streets and roads including water pipes. My service is publishing pipes. My service like ...
0
votes
0answers
66 views

FeatureLayer Mode_ONDEMAND notworking but Mode_SNAPSHOT is working

My web application is using ascgis javascript API 3.6 and I am trying to add FeatureLayer on Map. Layer is including buildings in a city. This is big data. Geometry type is polygon. I am adding ...
0
votes
2answers
681 views

Date Time format in ArcGIS 10.1

I have a Date column in my feature class and I want the date to appear in "dd MMM yyyy" format as a label to a polygon. I am using Arc Map 10.1. I tried taking Jscript. var Dt = new Date(); Dt = ...
7
votes
1answer
5k views

How to Add/Remove Legend with Leaflet Layers Control?

I have two overlays http://02d0c8c.netsolhost.com/dev/lcb_census_layers3.html that can be turned on and off with a Layer Control. I’d like the legend for each layer to turn on/off along with the ...
0
votes
0answers
135 views

ESRI add graphics to a layer via ajax call

I'm creating graphics layer with ajax return. I can see the graphics layer in the map, but the points don't appear on the layer, I'm adding the points but somehow something seems missing. Jen is an ...
0
votes
0answers
313 views

OpenLayers with Custom Map Tiles and Bounds - Bound and Rendering Issue

I am using a custom map image. And I have verified my lat, lon bounds via google maps. But when using the code below combined with my image - it sometimes returns a negative number for y based on ...
1
vote
3answers
158 views

Popups over markers not working in OpenLayers

I have a map developed based on google map API and OpenLayers. It has some markers on it. I'm trying to create a popup for each marker. The markers are in a markers layers. Besides the markers layer, ...
1
vote
0answers
181 views

View attachments in popup when using the editor widget

I am using ArcGIS javascript API to construct an editor app for a layer. I am using the default out of the box editor widget to edit and display data for an app. The layers I am editing contain ...
1
vote
0answers
234 views

maximum limit for plotting lat-long on google maps

I want to highlight a route on google maps along with our network sites. I have successfully done it but when I load data in large proportion then my plugin becomes unresponsive. Can someone suggest ...
3
votes
4answers
4k views

How to load external geojson file into leaflet map

I would like to load a geoJSON (polygon) file into my leaflet map. I have seen examples where geoJSON is embedded into the javascript code but I can't find any examples showing how it is done with an ...
0
votes
1answer
334 views

Open Layers Bounds with Lat / Long

I am using a custom map with the TMS in OpenLayers. I know my high/low latitude and longitude points. In other words I know the exact bounds of my map image in Lat/Long. Is there a way to use ...
2
votes
2answers
274 views

How do I sort a geoJSON feature collection alphabetically by a property value?

I am trying to sort the objects in a geoJSON FeatureCollection alphabetically by the values of one of their properties. How do I get to the nested object properties with JavaScript? I have tried using ...
2
votes
1answer
304 views

ESRI geoprocessing service with Javascript API 3.5

I am having issues getting a geoprocessing service to run. The service is a simple Python script that converts a table to CSV file. It runs fine in ArcMap. I can publish the service with the input ...
6
votes
2answers
480 views

Progress bar for Leaflet map

Is there any way to show progress bar while waiting that all layers are rendered on Leaflet map? In this specific case, while geojson layers are rendered. Thanks.
1
vote
1answer
359 views

How To Display ArcGIS Javascript API Graphic on Postback

This code uses ArcGIS JS API 3.5 to have a user designate a location on a map. It then blasts those coordinates into a SQL Server 2008 database and returns (using the confirm location button) some ...
0
votes
0answers
37 views

Getting longtitude lattitude from wfs on geoserver

i am making campus information system using geoserver, postgis and openlayers. on the javascript side i want to zoom selected classroom longtitude and lattitude (as google maps done--when you type any ...
1
vote
1answer
1k views

Bing Maps / JavaScript - trying to open InfoBox with the PushPin click event

I am experimenting with the sample code on the Bing SDK site but am unable to get the click event to work with the pushpins I am adding in a JS .each loop that pulls in longitude, latitude coordinates ...
2
votes
1answer
4k views

Zoom Change Event Listener with google maps api

I'm trying to create an event listener that turns off a google fusion layer once the map is zoomed in to a certain level. I'm pretty new to javascript and its google maps api, so any help is ...
0
votes
0answers
257 views

ESRI javascipt agsjs TOC works in version 3.0 but not 3.5 of the API

Is there a way to get the TOC.js to work in version 3.5?
0
votes
3answers
672 views

How to plot coordinates from *.csv file on Google Maps?

I want to highlight a mobile trace on Google Maps and GIS data from my network must also be visible. I am able to plot hard coded coordinates on Google Maps but not from a *.csv file. Note: *.csv ...
2
votes
1answer
161 views

ArcGIS 401 error during initialization of javascript map

I have a dumbed-down application to only reference a geometry service, and a feature service. When the map is being initialized, it sends out a GET request of: ...
2
votes
2answers
69 views

Why is OpenLayers only displaying the first features in my KML?

I have an OpenLayers map (that you can find here, use the blue search area) that reads in a KML string that is written from Perl using data from oracle. It reads the KML like this: var vector_Layer = ...
2
votes
0answers
38 views

simple raster format to use in Web applications?

I'm building a Web application in which users create and edit very coarse raster data. They're assigning values to cells in a georeferenced grid. Right now I'm storing the values in a multidimensional ...
2
votes
4answers
420 views

Get coordinates from address

I am writing a application which allow users to save a address into database (db) and in the next step it shows all addresses on a map. But in the saving step I need automatically calculate a GPS ...
2
votes
1answer
882 views

display a choropleth map using D3 and Leaftlet

I am trying to get a leaflet map to display a choropleth map using d3. I have written this code using samples I have found however the map just displays as the black fill, not the color classes I ...
2
votes
2answers
37 views

How do I know what parameters I can call for WMS layers?

I'm trying to learn OpenLayers but the documentation is hard to understand. For WMS layers, ex: var wms = new OpenLayers.Layer.WMS( "OpenLayers WMS", ...
-2
votes
3answers
99 views

Disable a button until selection is made [closed]

I have this section in my website: There is a drop down list of environments and an area for a user to input a Zip Code. What I am trying to achieve is making the button disabled until a selection ...
1
vote
1answer
155 views

OpenLayers serving a MapServer layer: data won't display correctly without using WMS

I am trying to serve my Mapfile data as a MapServer layer in OL, rather than a WMS layer. When I display it using WMS, everything works fine. The part of the mapfile I have struggled with was ...
0
votes
2answers
158 views

Programatically adding popups into OpenLayers map

I'm developing a web service and want to inset multiple popups dynamically to a web page according to the request. What I did was this <script> //injected programmatically var popups=[]; ...
1
vote
1answer
87 views

ArcGIS JS Modular Feature Layers? Possible?

My ultimate goal is a map which can toggle the visibility of layers on an ArcGIS map. However the data I need to use is not available as a feature service, I have to build it programatically from ...
1
vote
1answer
236 views

How to get bounding box coords?

How to get coords for NW and SE if we have about 4-5 pixels on the image with assigned latit/longit? I'm working on javascript app which would overlay that image on Google Map then. Thanks.
0
votes
1answer
216 views

OpenLayers: How to add permalink long/lat anchor to links outside of map on page

I would like to extend the funtionality of OpenLayers that appends, on-the-fly as the user zooms and pans the map, the longitude/latitude parameters as a anchor to the URL in the browser's address ...
0
votes
1answer
119 views

Undomanager did not remove graphics when undo()

My attempted on using the UndoManager has been unsuccessful for a couple days and I'm stuck. I did not setup a proxy. I create a FeatureLayer object in memory with var drawingPointLayer = new ...
2
votes
1answer
180 views

Application for online overlay images on Google Maps

I want to develop javascript app which will take any image user uploads, user will click on 3-4 points on the image (3-4 cities, for example NY, Chicago, LA and Miami) and image will be overlayed on ...
0
votes
2answers
189 views

javascript function to search all OpenLayers vector features covering a pixel

I have an OpenLayers map that draws features in a vector layer. The features are selectable and have a popup on select. Unfortunately in a lot of cases the features overlap so it can be impossible to ...