Skip to content

Instantly share code, notes, and snippets.

View jnewmoyer's full-sized avatar

Jason Newmoyer jnewmoyer

View GitHub Profile
@jnewmoyer
jnewmoyer / imagery_meta.js
Created September 25, 2017 18:14
Get imagery metadata from GeoServer WMS
$.ajax('http://backup.novasp.local:7880/geoserver/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&QUERY_LAYERS=collect&LAYERS=osm_hybrid_imagery%2Caoi%2Ccollect&INFO_FORMAT=application/json&FEATURE_COUNT=50&X=189&Y=201&WIDTH=256&HEIGHT=256&SRS=EPSG%3A4326&BBOX=125.145263671875%2C43.954925537109375%2C125.14595031738281%2C43.95561218261719', {
dataType: 'json',
error : function(jqXHR, statusText, errorThrown) {
console.log('error: ' + statusText);
},
success : function(data, statusText, jqXHR) {
if(data) {
var myObj = data;
console.log(myObj);
console.log('meta: ' + myObj.features[0].properties.meta);