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)

1
vote
2answers
760 views

OpenLayers.Class with OpenLayers.Control.GetFeature

I'm wondering if someone could point me in the right direction to force the BBOX of OpenLayers.Control.GetFeature to be always in long/lat coordinates. I'm trying to get this with OpenLayers.Class, so ...
4
votes
3answers
2k views

How to access an wms layer that requires authorization via OpenLayers?

Is there a way to send username and password parameter to a wms layer that needs authorization? If not, I guess it's perhaps a non-spatial thing to solve so that you before the javascript sends a ...
4
votes
1answer
1k views

Drawing Ellipse with OpenLayers

I am trying to draw ellipse on the client side using openlayers with some mathematical functions from drawing ellipse with svg. I have achieved drawing it but not rotation what I have written for ...
0
votes
1answer
756 views

how to find vertices for a geometry in OpenLayers

I am having a LineString, where I need to find the vertices logically and save those vertices. Can anyone help me out. Or else how below can help me. OpenLayers.Geometry.LineString = ...
4
votes
2answers
3k views

d3.geo.path() to draw a path from GIS coordinates

Trying to take GIS data of the zip codes of the Bronx and turn it into a map using d3.js. But I am having trouble rendering. Could you show me proper use of d3.geo.path() ? [ [ -73.84463693999993, ...
2
votes
1answer
216 views

passing geocode results object to another file

I'm using a geocoding plugin (Leafet.GeoSearch) on a map and I'd like the results, being the LatLng point coordinates, etc available as a parameter for GeoServer cql filtered calls. It doesn't seem ...
0
votes
1answer
496 views

Center a selected point on map. Openlayers + Geoext1 + ExtJs3.4

I've got an ExtJs combobox next to the map with several points of the map that are provided from a Postgis database through Php/XmlHttprequest. At the same time I've got a map with all points ...
5
votes
2answers
2k views

Turn Popups On/Off in ArcGIS Online Webmap via Javascript API Web Application

I am writing my first ArcGIS Javascript API web map application and consuming a web map authored in ArcGIS Online. The ArcGIS Online web map apparently does most of the work for me in terms of ...
3
votes
1answer
902 views

How to avoid corrupt geometries when translating between TopoJSON and GeoJSON?

I'm trying to display some geojson vector features on a leaflet map. The size of my GeoJSON is too big (25.4mb of data, 8.47mb gzipped), so I'm trying to use a TopoJSON format to reduce the size ...
1
vote
0answers
220 views

How to set up the layer order with Google Maps API?

I'm developing a web mapping site (using google maps api 3.0 and javascript) that combines wms layers and ground overlays (uploaded rasters) that are displayed on top of google maps. The software is ...
2
votes
1answer
1k views

Updating filter values and update map

I'm developing an ExtJS3.4-GeoExt1-OpenLayers2.12 GIS application. For basic functionality I need to filter layers to get specific data from a Geoserver WFS layer. Filter is done through the ...
0
votes
1answer
434 views

How to read/write a/from a file in javascript with prototype.js/jQuery.twFile support OR anyotherway

I want to write my data into a file from OpenLayers, I have gone through Prototype.js and jQuery.twFile.js or anyother way to write into a file.
1
vote
1answer
914 views

How to use filter in GeoExt.FeatureStore?

I have a FeatureStore: var protocol=new OpenLayers.Protocol.HTTP({ url: ...
0
votes
1answer
1k views

Plot points using ArcGIS javascript api from co-ordinates

I would like to map co-ordinates that I got from the exif in photo's using my own command line tool that I made. As opposed to uploading your private photo's for everyone to see on flickr. How to I ...
2
votes
2answers
1k views

Javascript library for converting MGRS to Lat/Lng

Is there a JS library that converts MGRS to LL? I have found one that converts Lat/Lng to MGRS, but nothing that converts MGRS to Lat/Lng. Someone asked this question in the past, but the answer was ...
0
votes
1answer
669 views

How to reproject layers (using GeoServer and OpenLayers) in order to overlay on the google maps [duplicate]

Possible Duplicate: Openlayers and Geoserver: OSM/Google Maps and WMS Overlay I am writing a code using OpenLayers. In this code, I want to display different layers in different zoom ...
5
votes
1answer
1k views

Does Leaflet has option for scale dependent layers?

Is it possible to show layers with Leaflet depending on scaling? For example not show counties until zoom level reaches 10. Thanks.
2
votes
1answer
1k views

Google Map API Drag event..?

The below code is working perfectly on click event to retrieve Lat/Long and Current Zoom level. How do I get the same when I hover mouse/drag on map Window (not on submit button)? <!DOCTYPE ...
1
vote
1answer
143 views

How to replace protocol in geoext.form.formpanel‏‏

I've been scratching my head over this and I'm wondering if this is possible. I want to replace the protocol of the GeoExt.form.FormPanel in the following way: to render the formpanel, I defined a ...
1
vote
1answer
2k views

Initializing Google Maps Streetview object looking at the position

I have a streetview included in my web site using google API to load it. var theloc = new google.maps.LatLng(lat, lon); var panoramaOptions = { addressControl: false, position: theloc, pov: { ...
1
vote
2answers
629 views

How to use Leaflet marker clustering with image map only?

I have image map of one state, where I would like to put about 100 markers. Is it possible to use only one image map instead of CloudMade tiles Leaflet usually uses? So, I need only that image to be ...
2
votes
1answer
474 views

Special background layer not coloring in Kartograph map

I'm testing out Kartograph according to the documentation and a linked gist. Both my US and non-US layers color correctly, but I can not get the special "sea" layer to fill. I found an example here ...
3
votes
2answers
271 views

“Hello World” introduction for ubuntuGIS?

Is the GIS equivalent of "Hello world!" = "You are here?" I installed ubuntuGIS recently, but I'm a little overwhelmed navigating the network of many packages to begin accomplishing simple things. ...
3
votes
1answer
1k views

How to add SLD to a wms layer dynamically from javascript

How to add SLD style which is written in String format and stored in a 'var' variable of javascript and asign it to a WMS layer while creating it.
3
votes
1answer
192 views

How to set up a maximal zoom for polygons in Leaflet?

How to set up a maximal zoom for some layer, for example state polygons? I need that my US polygons which represent states have maxZoom 6, and when zoomed higher than 6, that US counties show up ...
2
votes
0answers
947 views

Problem with multipolygon in Leaflet

I'm using Leaflet L.Polygon, but for some reason there's only blank site. Here's my code: var map = L.map('map').setView([37.8, -96], 4); var cloudmade = ...
1
vote
1answer
226 views

How to add more events like Control.Click and Handler.Point for a single variable in OpenLayers

I have two points which are marked dynamically on the map and when I mark the start point it is returning lon,lat, but I want to assign this coordinates to the variable that marked/handled the start ...
3
votes
0answers
96 views

How to PGRoute from OpenLayers via PostGIS/PostgreSQL [duplicate]

I need to route a shortest distance for a map which I have loaded from a PostgreSQL by means of JSON file. I can project the map in my browser and I can identify the linestrings. For a particular ...
3
votes
2answers
276 views

how to search for a Point of MultiLineString geometry in a json file using OpenLayers

I have a json file with large geometries(MultiLineString), here I got a Point among the json layer(baseLayer). I would like to search for a Point's LineString in the layer, from which MultiLineString ...
2
votes
1answer
89 views

Change text color of PopupMobile

I am facing the problem that with some mobile Browsers like DolphinHD and Android Browser that the browser makes the text color white, and the background is also white. So i want to change the ...
1
vote
2answers
62 views

accesing openlayers.map in index.html

I am developing an app using OpenTripPlanner. It creates an OpenLayer map in map.js. I want to access this map in index.html so I can set it's center. Kindly help me out.
9
votes
3answers
2k views

Chart inside pop up window in Javascript

How to show a chart inside pop up window? I'm using Leaflet JS, which has support for raphael plugin http://dynmeth.github.com/RaphaelLayer/. Is it possible to create a div inside popup window? I was ...
3
votes
1answer
344 views

Javascript and esri.dijit.PopupMobile

I currently have a wonderful mobile version of our site up in which it uses PopupMobile to display the requested info. I also map a button on the map that allows the user to do a random function. ...
6
votes
2answers
522 views

Rendering huge amount of points

Evening Guys, I am new to ArcGIS, and currently developing a small app that uses ArcGIS Javascript API. I have encountered a couple of problems while working on this and would greatly appreciate if ...
1
vote
2answers
1k views

Add layer in Openlayers using layer variable passed to a function with setVisibility

I am trying to add and remove layers by passing the name of the layer variable to two separate functions and I can't seem to find any place that describes what I am trying to do. Here is an abridged ...
0
votes
1answer
302 views

GeoExt2 - Popup Bug?

I'm using GeoExt2 (alpha) + Extjs 4.1 now to implement a map application. The thing is sometimes when I select a feature on the map, two popups are displayed. one at the bottom of the screen which has ...
3
votes
1answer
1k views

Problems with gxp Print plugin via opengeosuite sdk

I am trying to import the print plugin within an application built using the Opengeo Suite sdk and I have run into issues as is described in the following thread ...
5
votes
2answers
558 views

How to display a lot of images with OpenLayers?

I would like to display a lot of images at same time. The images are georeferenced (they have extents), with some labels on top of it which, on click, open popup. I can not say how many exactly ...
1
vote
1answer
694 views

Is it possible to show migration arrows on Leaflet map?

I need to develop Leaflet map which will show the whole world. Also, I need to draw some arrows which will show paths of migrations in the world. The important thing to say that those arrows need to ...
2
votes
1answer
155 views

Openlayers layer hide javascript menu

I have java-script menu that is getting behind openlayers OSM layer (only after it loads). I've tried giving z-index:9999 to the menu div but it didn't work. Any idea ?
2
votes
1answer
101 views

Whats steps can I suggest to achieve the best Geolocation Result

We are using Geolocation (getCurrentPosition()) in a website to determine a users position when using our site from a mobile device. I want to write an article explaining how the user can obtain the ...
1
vote
2answers
6k views

OpenLayers vector layer remove all features

I have a map (using OpenLayers) and a vector layer containing features(points). Sometimes I need to remove all features from the vector layer. When I use vectorLayer.removeAllFeatures() then it ...
2
votes
1answer
106 views

Is there a Deployment build of GeoExt 1.1?

The latest version of GeoExt that is available for download at http://geoext.org/downloads.html (version 1.1) appears to be a development version. They are individual files with whitespace and ...
2
votes
2answers
3k views

How to label GeoJSON polygons?

I'm using Leaflet combined with GeoJSON features. Is there a way to label GeoJSON features (in this case - polygons)? It should get labels from feature.properties.name This is my code where I ...
-1
votes
2answers
279 views

Go to the URL on click with GeoJSON

I'm using Leaflet API and geojson. I defined a function which zooms to the feature when clicked: function zoomToFeature(e) { map.fitBounds(e.target.getBounds()); } function ...
2
votes
1answer
400 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 ...
4
votes
2answers
2k views

Click link inside Leaflet Popup and do javascript

I have a leaflet map up and running. It overlays a series of polygons (via GeoJSON) on the map and attaches popups to each polygon. Each of the popups display information about that polygon. I'd ...
1
vote
0answers
428 views

translating and scaling viewport to fit geojson map in D3js

I am trying to load a map of Rio de Janeiro (Brazil) in GeoJson for with D3js the code and the map is here: https://gist.github.com/4157853 I can open the map normally with Qgis, but with d3js ...
0
votes
1answer
811 views

In leaflet does the addControl automatically handle events via the leaflet API?

I need to add additional overlay layers to be controlled by the controls within the leaflet map boundaries, but the code utilizes a leaflet-custom.js file. I am assuming it handles the event and ...
0
votes
0answers
114 views

How do I determine programmatically what values to add to the proj4js constructor for a CRS or SRS such that I can iteratively render proper overlays

I think this is primarily a GIS based question as far as for example: var crs = L.CRS.proj4js('EPSG:2154', '+proj=lcc +lat_1=49 +lat_2=44 +lat_0=46.5 +lon_0=3 +x_0=700000 ...