[GIS] How to integrate OpenLayers and ArcGIS Server

arcgis-serverfeaturesopenlayers-2popup

I am using the OpenLayers JavaScript API within a web application. I am displaying non-base layers hosted on an ArcGIS server. When I load the ArcGIS layers, I load them using OpenLayers.Layer.ArcGIS93Rest and by specifying the export service URL. The layer loads perfectly. However, when the user clicks on a feature, I want to be able to display a popup showing information about the feature that the user clicked on. Can anyone explain the best way to retrieve feature information?

Thanks in advance!

Best Answer

rest will solve your problems with only parsing it then adding to map. the following link has a query with geometry which return to results json.

filter geometry is -125.4,35.2,-118.7,43.8 

http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Specialty/ESRI_StateCityHighway_USA/MapServer/1/query?text=&geometry=-125.4%2C35.2%2C-118.7%2C43.8&geometryType=esriGeometryEnvelope&inSR=&spatialRel=esriSpatialRelIntersects&relationParam=&objectIds=&where=&time=&returnCountOnly=false&returnIdsOnly=false&returnGeometry=true&maxAllowableOffset=&outSR=&outFields=&f=pjson

you can get more information here ArcGIS Server REST API. and you can also get another info here ArcGIS Server REST API, OpenLayers

i hope it helps you...

Related Question