Tag Info

New answers tagged

0

This is also an answer - you can use the appendTo function: $("#source") .appendTo("#destination"); I found the answer here on Stackoverflow:


0

The reason for the delay was because of the angular $apply digest cycle. Angular basically wasn't aware of the changes to hoveritem. Wrapping it with $scope.$apply did the trick: $scope.$apply(function () { $scope.hoveritem = layer.feature.properties.id; })


1

This API link from EPA shows the Watersheds http://watersgeo.epa.gov/arcgis/rest/services/NHDPlus_NP21/WBD_NP21_Simplified/MapServer?f=jsapi - raw ...


1

It looks like you found the service to use ... http://watersgeo.epa.gov/arcgis/rest/services/NHDPlus_NP21/WBD_NP21_Simplified/MapServer/ Just plug that in to one of the many samples available and start from there. Go Here and click "Browse Samples" https://developers.arcgis.com/javascript/ Find one that does something similar to what you want to do (or ...


0

I don't work with APIs am not exactly sure what you are looking for, but watershed boundary data is available and downloadable as polygon shapefiles from multiple websites. For example, ftp://ftp.ftw.nrcs.usda.gov/wbd/ allows one to download maps at different watershed (HUC) scales. When you say "watershed boundary" you also need to specify at what ...


0

You can set the formatting for the date attributes in your template using the built in support. The format is ${FIELD_NAME:FORMAT_FUNCTION_NAME(OPTION_A: value, OPTION_B: value)}. So for dates you can use something like ${DATE:DateFormat} or ${DATE:DateString}. There are more options documented at the format info window help page. Hopefully you can find the ...


0

Google allows you style the map tiles themselves. You won't need the CartoDB API for this. It's not a true "opacity" of the map layer, but you can use the map style to change the lightness of the map tiles to achieve what I believe is the effect you want. Check out https://developers.google.com/maps/documentation/javascript/styling for examples. However ...


1

Hey plain CSS did the trick: .leaflet-container { background-color:rgba(255,0,0,0.0); }


1

solved It: function calculateArcPointsGeo(center, radius, startAzimuth, endAzimuth, segments) { var pointList = [], point, i, d = radius / 1000, // d = distance in km R = 6371, // km, R = earth's radius (mean radius = 6,371km) lat1 = deg2Rad(center.Y), lon1 = deg2Rad(center.X), ...


0

You may try inspecting the object that has your list of items and building a new one containing the single instance of the strings in the old object. This sounds like what you might be trying to do. If not, then please let me know and i will refine the approach, as appose to simply down voting me ;). The idea is to filter your object with duplicates by ...


2

Basically I just set a count attributes as the following codes: data.push( { attributes: {count:commuterAmt}, geometry: { spatialReference: { wkid: 102100 }, type: "point", x: coordXicon, y: ...


2

The basic algorithm is to check every segment of the polygon and find the closest point for it. This will either be the perpedicular point (if it is on the segment) or one of the endpoints. After doing this for all segments, pick the point with the smallest total difference. So in your example it would be the segments: AB, outside, pick B BC, inside, try ...


2

Find the two nearest points to your point; just do this with pythagoras, but don't sqrt, you don't need the distance, only the order. Work out the gradient between these two points (y1-y2)/(x1-x2) where 1 is one of the points and 2 is the other. This is from solving y=mx+c for m for the two points (simultaneous equation). Then use one of these points to ...


0

We had similar problem in one of our projects.We've used open layers 2 modify feature (http://openlayers.org/dev/examples/modify-feature.html) to implement editing topology and it works quite well.You can implement some simple basic checks on the client side (open layer have a good support for working with geometries), but we've decided to do most of them on ...


5

You can get it with JSTS. Check DistanceOp.js.


2

Thanks for the clarification. It appears that you are mixing the ArcGIS JS API's map object with the Google Maps API's heatmap functionality. This is highly unlikely to work. Instead you could look at the ArcGIS Server JS API's heatmap functionality. This isn't officially supported but stands a better chance of working - see ...



Top 50 recent answers are included