function selectParcel(parcelid) { if (parcelid) { var query = new Query(); query.where = "PARCELID = '" + parcelid + "'"; var deferred = parcels.selectFeatures(query, FeatureLayer.SELECTION_NEW, function (selection) { var center = graphicsUtils.graphicsExtent(selection).getCenter(); // add parcel to browser history var apn = selection[0].attributes.APN; if ((typeof history.pushState !== "undefined") && (apn)) { window.history.pushState(null, null, "?getParcel=" + apn); } var extHandler = map.on("extent-change", function () { extHandler.remove(); //zoom to the center then display the popup map.infoWindow.setFeatures(selection); map.infoWindow.show(center); }); map.centerAt(center); }); } }
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.