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

learn more… | top users | synonyms

0
votes
0answers
12 views

applyEdits method and File on arcgis feature service

I would like to know if it's possible to upload a file through the applyEdits method on a feature service? I have an Oracle database with a parameter "DOCUMENT" of type BLOB. I would like to upload ...
2
votes
2answers
50 views

How to insert coordinates to url

What would be the approach to show and dynamically update the map coordinates in the url like stamen is doing it? Are there any built in functions in OpenLayers, what other techniqes could I use or do ...
0
votes
0answers
19 views

random point in geometry (JavaScript, OpenLayers)

I have a standard OpenLayers geometry object - in 90% of cases it is a polygon and in 10% a multipolygon. I need to get a random point in that geometry. I cannot just tase a random border point (using ...
1
vote
0answers
26 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
0answers
14 views

Which are the differences between using javascript openlayer and gwt-openlayer API?

I am about creating a web app which should use openlayer API, but I would like to use GWT too. So I have the following questions: Is it the same to use GWT-openlayers API in terms of functionality ...
1
vote
1answer
30 views

ArcGIS API for JavaScript - Adding Point(s)

I need to add a single point, I am new to JS and ArcGIS API. I was looking for some code examples on how to create a point and/or a few other points (as needed) I can't use any additional ...
1
vote
1answer
30 views

How to get the TOC to update after adding a new Layer in the ESRI JSAPI?

I am developing an Web map with the ESRI's JavaScript API v 3.9. I am using the TOC widget available at http://www.arcgis.com/home/item.html?id=9b6280a6bfb0430f8d1ebc969276b109 The documentation ...
0
votes
1answer
47 views

How to fire .NET code in my ArcGIS application from javascript?

So I'm developing a .NET desktop application for ArcGIS in VB. As a new part of the application I have developed an SVG / Javascript map as a 'loading screen' where you select your dataset to load ...
0
votes
1answer
28 views

How to forbid zoom map under scroll page?

I wrote code at ArcGis JavaScript. There is a map on web page at full display with a fixed height (400px) When i scroll-down page and cursor misses in zone map then browser works for zooming map, not ...
0
votes
1answer
69 views

Leaflet Custom Control Fails

Why does the myMenu control not respond to a click? var map = L.map('map').setView([51.505, -0.09], 13); L.tileLayer('https://{s}.tiles.mapbox.com/v3/{id}/{z}/{x}/{y}.png', { maxZoom: ...
3
votes
1answer
66 views

Is there a way to know if an error occurred while loading a WMS layer, in OpenLayers 2?

First of all, I already asked this question in stackoverflow. I don't want to spam by asking again here. But I think the question fits better in gis.stackexchange. I am sorry for the replication. Feel ...
0
votes
1answer
76 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
26 views

Trouble adding tabs in identity popup JS API

May 28 Edit I have edited my code a bit and have come up with a fix to the tab container, however I am now having troubles getting my attributes to show when I click on one of my service layers. ...
0
votes
1answer
40 views

Map generation failing with Kartograph.js

I am trying to generate a very simple map using kartograph.js. But some how my code is not working. <html> <head> <script src="jquery-1.8.3.min.js"></script> ...
0
votes
0answers
36 views

Call a service web from a ComboBox using JavaScript

I want to call a web service and use it in combox for search. Here is the function that i used to call my service web: var xmlhttp = new XMLHttpRequest(); var url = ...
1
vote
0answers
47 views

How to combine three data extraction functions into one button?

I am looking to simplify my code. As of right now I have some code that allows users to extract GIS data in three different ways: Extract by drawn extent Extract by extent of the a county Extract by ...
0
votes
1answer
26 views

Passing RasterDataSource object to RasterData object in Javascript API?

I have a GP service that requires a RasterData object as input. The RasterData object should hold a RasterDataSource object, but I'm not sure of the syntax to connect these two classes. The API ...
0
votes
1answer
59 views

Modify the Zoom Buttons in ArcGIS.com JavaScript Application

I'm writing a JavaScript application to view web maps from ArcGIS.com. It is similar to the sample found on Esri's Samples page: http://developers.arcgis.com/javascript/samples/ags_createwebmapid/ ...
0
votes
0answers
49 views

Using postgis functions in ArcGIS Server 10.2 for Layer Definition Query

I asked the previous question Using PostGIS functions in ArcGIS Desktop for Layer Definition Query? And got an excellent answer. However this covered ArcGIS Desktop. In 10.0 it seemed that if I got ...
1
vote
0answers
32 views

Openlayers filter strategy on wfs deactivate problem

I have a filter control which works nicely. However, when I try to reset/remove the filter, I don't get the original features back. The debugger shows my features array as still only being the reduced ...
0
votes
2answers
49 views

Add an individual layer from ArcGISDynamicMapServiceLayer to the map

I have a ArcGISDynamicMapServiceLayer containing many layers. I'd need to add only individual layers to the map, like layers 2,5 and 10. The following code would add all the layers to the map: url = ...
0
votes
1answer
86 views

Calculate distance and surface with mapbox api

Is there a way to draw lines and polygons (with geojson) and calculate distance and polygon surface with the mapbox api or leaflet? I wish to have the same tools as in geojson.io with the extra ...
0
votes
0answers
22 views

feature position on non-Geo-referenced Image

I use OpenLayers to show Map , when im creating the map, i want to show map image with an ImageLayer and VectorLayers, the image is non Geo-referenced. The use case: i receiving a map image url from ...
0
votes
0answers
58 views

Print OpenLayers map with osm as background and all the vectors

I looking for an answer for a while, and i could not find a working solution. I am trying to exeport the OpenLayers map to some file - image or pdf, and i need all the background, include OSM and all ...
1
vote
0answers
76 views

How to drag a feature in Open Layers 3

I'm trying to replicate something that was fairly easy in Open Layers 2 in Open Layers 3, which is: dragging an existing feature to a new location on the map. In Open Layers 2 I just added a ...
1
vote
0answers
13 views

Make InfoTemplate moveable but still highlight attributes

I’m using the esri/InfoTemplate in the Javascript API to identify features. However, it gets anchored to the mouse click and cannot be moved around. Based on this answer I used dojo/dnd/Moveable to ...
0
votes
0answers
42 views

Land Parcel and JSON Data with onclick event

I currently am working on a school project and have been introduced to javascript with little knowledge. What the project entails is a webapp of land parcels that contain information about each one, I ...
1
vote
1answer
59 views

Openlayers - ModifyFeature - How to label vertices with a progressive number

Apologize in advance as I am quite new in openlayer and javascript. I have a control ModifyFeature on a path vector layer. I would like the vertices to be rendered with a stylemap label showing ...
4
votes
1answer
77 views

Show markers only at certain zoom levels

I'm building a cycle touring map in leaflet.js, with subjective information overlaid as markers, along the lines of "this is a great road", "this town is quite nice" etc. To avoid information ...
1
vote
1answer
110 views

Function to add layer with button click

I'm working with openlayers and geoserver to create a map and overlay layers. I need to add a layer when a button is clicked, but what I get is that the layer is added ( i can see it through the layer ...
0
votes
0answers
30 views

web map with arcGIS for server and javascript?

How would I go about creating a feature layer from Arcmap, and saving it as a service to arcGIS for server, which I could call from javascript API, so the web map will provide user interaction. For ...
0
votes
1answer
70 views

Infowindow split string by comma

I might have went about this the wrong way, though I thought it may be a good idea to ask before starting over again. I have a picture column in cartodb which has multiple picture ids separated by ...
1
vote
1answer
206 views

openlayers - export map to canvas problem

I am trying to make a export control to export the map as image file. I found this example: http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/exportMapCanvas.html so i added the ...
0
votes
2answers
45 views

queryTask - execute vs executeForIds

When setting up a queryTask, what's the difference between queryTask.execute() and queryTask.executeForIds()? In ESRI's JS API Reference, they have the exact same descriptions: ...
0
votes
1answer
109 views

TitlePane not rendering - working with basemapGallery sample code 2

I'm having the exact same issue as this question: TitlePane not rendering - working with basemapGallery sample code but the solution doesn't work for me. my javascript: ...
0
votes
0answers
16 views

Is there a way to create a named symbol in OpenLayers composed as either a multi-dimensional array or as a MultiPolygon?

OpenLayers provides a minimal set of "well-known" shapes which can be used as point icons: /** * Constant: OpenLayers.Renderer.symbol * Coordinate arrays for well known (named) symbols. */ ...
0
votes
0answers
21 views

Display one of many rasters in Web Map

I would like to interactively add a georeferenced tif to my webmap. Use case is: I have a raster catalog of georeferenced tax maps. I would like to be able to select those tax maps (there are ...
0
votes
1answer
34 views

ArcGIS JS - Feature Layer selection symbol before layers loaded

I have a feature layer that is dynamic and could pull a geometryType: esriGeometryPoint or geometryType: esriGeomertyPolygon I was wondering how would I know when to set the selection symbol to ...
0
votes
0answers
33 views

Query results feature set to a brand new Features set

Here what I am trying to do: 1) My overall goal is to query an extent and to extract data by this extent. I can successfully achieve the first part. 2) Here is my issue: The Dynamic layer queried has ...
1
vote
1answer
101 views

How do I plot a line on a map, or obtain the latitude and longitude coordinates of such a line, that is 120km north of the US-Canada border?

How do I plot a line on a map, or obtain the latitude and longitude coordinates of such a line, that is 120km north of the US-Canada border, including parts of the border that cross water? (I managed ...
0
votes
0answers
23 views

Access multiple feature servers through ArcGIS REST API

we are adapting a web app to support an ArcGIS server back end through the use of Javascript ajax calls which in turn display the data using Leaflet. The current version of the application runs ...
0
votes
0answers
15 views

How to run GeoAdmin3

I coloned Geoadmin repo from github. I tried tu run this localy but no sucess. I have my own rc_ file but still it's not working. Anyone can help me?
0
votes
0answers
23 views

map stops at map.graphics.add(graphic);

function getLocRes(results) { //map.graphics.clear(); var symbol = new esri.symbol.SimpleFillSymbol(esri.symbol.SimpleFillSymbol.STYLE_SOLID, new ...
0
votes
0answers
57 views

Customizing map.on(“click”) while using default editor widget

My question is whether or not it is possible to use the default editor widget in my case given the needs of my application. My map consists of points displayed from four different FeatureLayers. They ...
0
votes
2answers
90 views

ArcGIS Javascript API - switch case to display attributes in a popup

var vliTemplate = new InfoTemplate("Visual", "<tr><b>VLI Number:</b> <td>${VLI_VLI_NO} </tr></td>"+ "<br><tr><b>Not Greened Up ...
0
votes
1answer
45 views

problem login geoexplorer - redirect IP

I have problems when I want to log the administrative user through GeoExplorer when geoserver is running on a server with public ip but redirection to a private ip. GeoExplorer takes too long to load ...
0
votes
0answers
22 views

Customize LabelLayer extent based on density/location using ArcGIS JavaScript API

I'm using a LabelLayer that can be seen only within a certain minScale - maxScale window. I'm trying to display labels of census tract IDs within Illinois, and the difference in label density between ...
0
votes
0answers
27 views

Openlayers WFS change featureType

I am trying to change wfs featuretype "on the fly" in openlayers. (This method http://dev.openlayers.org/docs/files/OpenLayers/Protocol/WFS/v1-js.html#OpenLayers.Protocol.WFS.v1.setFeatureType) This ...
0
votes
0answers
31 views

GP clip and ship crash. Any idea?

I have been trying to implement this code for a few weeks but always run into new issues. It seems like everything is working fine now except my clip and ship GP. It always returns the GPerrorFailed ...
0
votes
0answers
23 views

Handling Popups in Leaflet with Overlapping Features

I am new to Leaflet as well as Javascript, and I'm looking for some advice on a basic topic. Currently, I am trying to create a spatial index of library holdings for old topographic maps that people ...