function get_nextsibling(n)
{
x=n.nextSibling;
while (x.nodeType!=1)
  {
  x=x.nextSibling;
  }
return x;
}

function print_specs(currentid)
{
if (window.XMLHttpRequest)
  {// code for IE7+, Firefox, Chrome, Opera, Safari
  xmlhttp=new XMLHttpRequest();
  }
else
  {// code for IE6, IE5
  xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 && xmlhttp.status==200)
    {
    xmlDoc=xmlhttp.responseXML;
    var txt="";
    x=xmlDoc.getElementsByTagName("keyid");
    for (i=0;i<x.length;i++)
      {
	tagvalue = String(x[i].childNodes[0].nodeValue);

	if (tagvalue == currentid) {

          artist=get_nextsibling(x[i]);
          color=get_nextsibling(artist);
          size1=get_nextsibling(color);
          size2=get_nextsibling(size1);
          baseprice=get_nextsibling(size2);

	txt = txt + "<p><strong>Media</strong>: 100\% acid-free cotton rag art paper. </p>";
	txt = txt + "<strong>Available sizes</strong>: <p><ul><li>" + size1.childNodes[0].nodeValue + "</li>"
	
        if (document.getElementById(size2)!=null) {
 	   txt = txt + "<br><li> and " + size2.childNodes[0].nodeValue + "</li>";
	}
	txt = txt + "</ul></p><p><strong>Color</strong>: <ul>" + color.childNodes[0].nodeValue + "</ul></p>";
        txt = txt + "<p>Soft white is white without any bleaches or brighteners.</p>";
	txt = txt + "<p><strong>Price</strong>: $" + baseprice.childNodes[0].nodeValue + "</p>";
	txt = txt + "<p><strong><a class=\"menuItem\" href=\"http://www.ccnow.com/cgi-local/cart.cgi?xineann_" + tagvalue + "_http://www.artsycraftsy.com/";
        txt = txt + artist.childNodes[0].nodeValue + "_prints.html\"><img src=\"http://www.artsycraftsy.com/im/cart.gif\" border=\"0\" hspace=\"5\" ";
        txt = txt + "alt=\"Add to Cart\">Add to Cart</a> </strong> (Choose paper size, estimate shipping costs. You can change quantities or remove it later.)</p>";
        txt = txt + "<p><p><strong><strong>Credit Cards</strong>: Online orders are processed through CCNOW.  CCNow will appear on your credit card statement. 
<p>
<strong>Trouble ordering?</strong>:  Call us at 805 567-4677 for orders only, please.  You can also <a class="menuItem" href="http://www.lightlink.com/xine/print_invoice.html">contact us</a> to request an invoice or ask a question.</p>
?</strong>:  You can <a class=\"menuItem\" ";
        txt = txt + "href=\"http://www.lightlink.com/xine/print_invoice.html\">request an invoice</a>.</p>";
        txt = txt + "<p><strong>Discount</strong>: Free or discounted shipping on two or more.</p>";
        txt = txt + "<p><strong>Guarantee</strong>: Return your art print within 15 days in original condition for full refund (less shipping). </p>";
        txt = txt + "<p><strong>Credit Cards</strong>: Our credit ca<strong>Credit Cards</strong>: Online orders are processed through CCNOW.  CCNow will appear on your credit card statement. 
<p>
<strong>Trouble ordering?</strong>:  Call us at 805 567-4677 (orders only, please).  You can also <a class="menuItem" href="http://www.lightlink.com/xine/print_invoice.html">contact us</a> to request an invoice or ask a question.</p>
rd orders are processed through CCNow. CCNow will appear on your credit card statement.</p>";
       
	  }
	      
      }
      document.getElementById("myDiv").innerHTML=txt;
   }
  }
xmlhttp.open("GET","parrish.xml",true);
xmlhttp.send();
}



