Tag Info

New answers tagged

1

Since you're already looping through data.rows, which contains the data, this looks more like a Bootstrap question. I've just done an example of html table from CartoDB SQL API data with plain JS: <script> var table = document.getElementById('mytable'); var sql = cartodb.SQL({ user: 'documentation' }); sql.execute("select adm0name, name ...


5

The problem is that your string inputFeature_json has special characters that are not in the ascii encoding. If you have characters that are not in the english alphabet they can cause encoding errors. Try to convert the string as unicode. for example: # Script arguments inputFeatures_json = arcpy.GetParameterAsText(0) #wtite to file jsonFileName = ...


1

proj4.js uses string and array functions (e.g. .split(), .map()) which are not built in to older browsers. es5-shim (https://github.com/es-shims/es5-shim) fixes this; just load this JavaScript library before anything else (it is benign for newer browsers).


2

A MultiPoint, by definition, comprises several points, so geom = '{"type": "MultiPoint", "coordinates": [[100.0, 0.0], [101.0, 1.0]]}' geom = ogr.CreateGeometryFromJson(geom) # iterate through the points for i in range(0, geom.GetGeometryCount()): g = geom.GetGeometryRef(i) print "%d,%d" % (g.GetX(), g.GetY()) 100,0 101,1 as explained in Iterate ...


0

One thing that's wrong is your first and last coordinates need to be the same for a polygon. I'd get rid of your first two points (since lat and long are reversed). I pasted a fixed version for you here jsbin.com fixed json


0

You can easily solve this with something like (Javascript code) var dataRows = [{ id: 1, geom: "LINESTRING(-1.131510412 52.65531, -1.13286 52.65559)" }]; features = []; dataRows.forEach(function (row) { var coords = row.geom.replace("(", "[").replace(")", "]").substring(row.geom.indexOf("("), row.geom.length); ...


0

You need to create the layer and add it to the map's list of layers. You can just add the properties to the feature and then add that feature to the source for the layer. You can later access any of these properties with feature.get('altitude') for example. I would try doing something like this: var markerSource = new ol.source.Vector(), markerLayer = new ...


0

you can utilize cartoview to display your ArcGIS Server services on Leafletjs, the basic viewer and the feature detailed apps of cartoview both utilize the ESRI Leafletjs plugin, take a look at www.cartologic.com/cartoview



Top 50 recent answers are included