function MuestraNombre(str)
{
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)
    {
    document.getElementById("muestraarticulos").innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET","articulos.php?Cadena="+str,true);
xmlhttp.send();
}

//-----------------------------------------------------------------------------

function MuestraNombre2()
{
if(document.getElementById('seltipo').value>=0){
	var tipo=document.getElementById('seltipo').value;
	}
else{
	var tipo="-1";
	}

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)
    {
    document.getElementById("muestraarticulos").innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET","articulos.php?tipo="+tipo,true);
xmlhttp.send();
}

//-----------------------------------------------------------------------------

// function listapack(str)
// {

// 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)
    // {
    // document.getElementById("articulopack").innerHTML=xmlhttp.responseText;
    // }
  // }
// xmlhttp.open("GET","muestrapack.php?pack="+str,true);
// xmlhttp.send();
// }

function listapack(str){
var xmlhttp = false;  
    try 
    { 
     // Creacion del objeto AJAX para navegadores no IE
     xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); 
    }
    catch(e)
    { 
     try
     {
      // Creacion del object AJAX para IE 
      xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); 
     } catch(E) {
      xmlhttp=false;
     }
    }
    if (!xmlhttp && typeof XMLHttpRequest!='undefined')
    {
     xmlhttp = new XMLHttpRequest();
    } 
xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 && xmlhttp.status==200)
    {
    document.getElementById("articulopack").innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET","muestrapack.php?pack="+str+"&rand="+Math.random(),true);
xmlhttp.send();
}
   
function muestraDesc(tipo)
{
var xmlhttp = false;  
    try 
    { 
     // Creacion del objeto AJAX para navegadores no IE
     xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); 
    }
    catch(e)
    { 
     try
     {
      // Creacion del object AJAX para IE 
      xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); 
     } catch(E) {
      xmlhttp=false;
     }
    }
    if (!xmlhttp && typeof XMLHttpRequest!='undefined')
    {
     xmlhttp = new XMLHttpRequest();
    } 
xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 && xmlhttp.status==200)
    {
    document.getElementById("capadesc").innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET","descripcionpack.php?tipo="+tipo+"&rand="+Math.random(),true);
xmlhttp.send();
}

function MuestraDesign(str)
{
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)
    {
    document.getElementById("muestradesign").innerHTML=xmlhttp.responseText;
    }
  }
xmlhttp.open("GET","muestradesign.php?Cadena="+str,true);
xmlhttp.send();
}
