首页 > 其他 > 详细

openlayers read xml

时间:2015-01-19 22:32:05      阅读:331      评论:0      收藏:0      [点我收藏+]

       OpenLayers.Request.GET({
            url: "/Panos/" + name + "/Editer" + name + ".xml",
            success: function (request) {
                var direction = 0;
                var panoXmlFormat = new OpenLayers.Format.XML();
                var panoXml = panoXmlFormat.read(request.responseXML || request.responseText);
                if (panoXml.documentElement.getElementsByTagName(‘hotspot‘)) {
                    direction = parseFloat(panoXml.documentElement.getElementsByTagName(‘hotspot‘)[0].getAttribute(‘direction‘));
                }
                ShowPanorama(name, evt.feature.geometry, direction);
            },
            failure: function () {

            },
            scope: this
        });

openlayers read xml

原文:http://www.cnblogs.com/firekylin/p/4234804.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!