我在linux机器上托管了一个基于ArcGIS Javascript API的地图。地图有很多弹出窗口,每个弹出窗口依次有一个按钮。是否可以通过弹出窗口中的按钮运行shell脚本或系统命令?谢谢!
编辑:添加了代码段!
function pageReady() {
var popup = new esri.dijit.Popup({
fillSymbol: new esri.symbol.SimpleFillSymbol(esri.symbol.SimpleFillSymbol.STYLE_SOLID, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([255,0,0]), 2), new dojo.Color([255,255,0,0.25]))
}, dojo.create("div"));
var initExtent = new esri.geometry.Extent({"xmin":-13626637,"ymin":4550020,"xmax":-13624728,"ymax":4551042,"spatialReference":{"wkid":102100}});
map = new esri.Map("map",{
infoWindow:popup,
outFields: ["*"]
});
dojo.addClass(map.infoWindow.domNode, "myTheme");
dojo.connect(map,"onClick",function(evt){
var query = new esri.tasks.Query();
query.geometry = pointToExtent(map,evt.mapPoint,10);
var deferred = featureLayer.selectFeatures(query,esri.layers.FeatureLayer.SELECTION_NEW);
map.infoWindow.setFeatures([deferred]);
map.infoWindow.show(evt.mapPoint);
});
var basemap = new esri.layers.ArcGISTiledMapServiceLayer("http://server.arcgisonline.com/ArcGIS/rest/services/ESRI_Imagery_World_2D/MapServer");
map.addLayer(basemap);
拉姆
答案 0 :(得分:0)
我使用了网络套接字并解决了这个问题。感谢大家的投入!