i want to select just two items from xml file with itemno and quantity that have less prices.can anybody help me how to do this in javascript.
items.xml:
<?xml version="1.0"?>
<items>
<item>
<itemno>1</itemno>
<unitprice>99</unitprice>
<Quantity>10</Quantity>
</item>
<item>
<itemno>2</itemno>
<unitprice>80</unitprice>
<Quantity>10</Quantity>
</item>
<item>
<itemno>3</itemno>
<unitprice>120</unitprice>
<Quantity>10</Quantity>
</item>
</items>
javascript:
var xmlDoc=new ActiveXObject("MSXML.DOMDocument");
xmlDoc.async="false";
xmlDoc.load("items.xml");
var items=xmlDoc.documentElement;
var item = itemss.childNodes(0);