Ò»¸ö¿Í»§Ìṩһ¸ö¹É¼ÛµÄÐÅÏ¢£¬ÒªÇó·ÅÔÚÒ³ÃæÉÏ£¬ÏÔʾһЩÊý¾Ý£¬ÐèÒª´ÓÔ¶³Ì»ñÈ¡xml£¬È»ºó½âÎöдÔÚÍøÒ³ÉÏ£¬¿ªÊ¼²»»á¾õµÃºÜÄÑ£¬ÆäʵÂù¼òµ¥µÄ£¬ÏÈÓÃjavascriptдÁËÒ»¸ö£º
ÒÔÏÂΪÒýÓõÄÄÚÈÝ£º
<script language=javascript>
var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async="false";
xmlDoc.load("http://****.com/scripts/****.asp?subcode=C22");
nodes = xmlDoc.documentElement.childNodes;
var text = xmlDoc.selectSingleNode("//last").text
document.write(text);
</script>
http://****.com/scripts/****.asp?subcode=C22 ,ÊÇ¿Í»§ÌṩµÄÒ³Ã棬ÆäʵÊÇxmlµÄÄÚÈÝ£¬ÕâÀïÖ±½Óµ÷ÓÃwindowsµÄ×é¼þ½øÐжÁÈ¡£¬È»ºóµ÷ÓÃÆäÖÐÒ»¸öselectSingleNodeµÄ·½·¨£¬¶Á³ölast×ֶεÄÄÚÈÝ£»
VBscriptҲдÁËÒ»¸ö£¬Æäʵ²î²»¶à£¬²»¹ýÓÐÒ»µã²»Í¬£¬aspÖÐVBµÄ²»ÄÜÖ±½Ó¶ÁÈ¡Ô¶³ÌxmlµÄÄÚÈÝ£¬ºÜÆæ¹Ö£¬²»ÖªµÀÊDz»ÊÇÓÉÓÚVBµÄÏÞÖÆ£º
ÒÔÏÂΪÒýÓõÄÄÚÈÝ£º
dim XMLMorntekDocument
Set http=Server.CreateObject("Microsoft.XMLHTTP")
http.Open "GET","http://****com/scripts/******.asp?subcode=C22",False
http.send
Set XMLMorntekDocument=Server.CreateObject("Microsoft.XMLDOM")
XMLMorntekDocument.Async=False
XMLMorntekDocument.ValidateOnParse=False
XMLMorntekDocument.Load(http.ResponseXML)
price = XMLMorntekDocument.selectSingleNode("//last").text
response.write price
Set http=Nothing
Set XMLMorntekDocument=Nothing
ÕâÀïÏÈÓÃXMLHTTPµÄ·½·¨£¬getµ½xmlÎļþ£¬È»ºóÔÙ½âÎö