var zpoblacion
var zcp
var zprovincia
var zpais
var ztipocliente
var zdiafecha
var zmesfecha
var zyearfecha
var anom;
var sesion;
var chkey;
var chlog;
var bck;
function valorascci()
{
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/getanonimo?"
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { anom = e.responseText ; }
}
, onFailure: function(e) {
alert('Error en la lectura de los datos');
}
});
return false;
}
function showcontra(donde,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/formcontra?workidioma="+workidioma+"&idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
$(donde).innerHTML=url;
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function getcontra(donde,idses,idanon)
{
m = $('mailcontra').getValue();
if (comprobarMAIL(m)==true)
{
$('errormail').style.display="none";
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/contra?workidioma="+workidioma+"&idsesion="+sesion+"&idanonimo="+idanon+"&mail="+$('mailcontra').getValue()
url=url+"&sid="+Math.random()
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
";
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
else
{
$('errormail').style.display="block";
}
}
function formregistro(donde,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
document.location.href='#';
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/formregistro?workidioma="+workidioma+"&idsesion="+idses+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get',
onSuccess: function(e) {
if (e.responseText != "") { $('submenu').style.display="none";$(donde).innerHTML = e.responseText ;writepoblacion();writecp();writeprovincia();writepais(); writetipocliente();writediafecha();writemesfecha();writeyearfecha();}
}
});
}
function registrarse(donde){
document.location.href='#';
var text="";
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/check?key="+$('key').getValue()+"&keyuser="+$('keyuser').getValue()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { chkey = e.responseText ; }
}
});
if ($('loginreg') != null){
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/checklogin?login="+$('loginreg').getValue()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { chlog = e.responseText ; }
}
});
}
if ($('nombre').getValue()==""){
text = "El campo NOMBRE es obligatorio \n";
}
if ($('apellido1').getValue()==""){
text = text+"El campo APELLIDOS es obligatorio \n";
}
if ($('cif').getValue()==""){
text = text+"El campo CIF es obligatorio \n";
ret=false;
}
if ($('mobil')!=null){
if ($('mobil').getValue()==""){
text = text+"El campo TELEFONO MÓVIL es obligatorio \n";
ret=false;
}
}
m = $('email').getValue();
if (comprobarMAIL(m)==false){
text = text+"El MAIL no tiene un formato correcto (formato xxxx@yyy.zzz) \n";
}
if (ztipocliente != null) {
if (ztipocliente.getComboText()==""){
text = text+"El Tipo de Cliente es obligatorio \n";
ret=false;
}
}
if ($('direccion').getValue()==""){
text = text+"No ha introducido la dirección \n";
ret=false;
}
if ($('poblacion').getValue()=="") {
text = text+"El campo POBLACIÓN es obligatorio \n";
ret=false;
}
if ($('cp').getValue()==""){
text = text+"El campo CÓDIGO POSTAL es obligatorio \n";
ret=false;
}
if ($('provincia').getValue()==""){
text = text+"El campo PROVINCIA es obligatorio \n";
ret=false;
}
if ($('pais').getValue()==""){
text = text+"El campo PAÍS es obligatorio \n";
ret=false;
}
if ($('loginreg') != null){
if ($('loginreg').getValue()==""){
text = text+"El campo NOMBRE DE USUARIO es obligatorio \n";
ret=false;
}
}
if (chlog=="1"){
text = text+"Este nombre de usuario ya figura en nuestra base de datos, si usted se registro en algún otro Salón, acceda con su Nombre de Usuario y Password para obtener la pre-acreditación. \n";
ret=false;
}
if ($('passreg') != null){
if ($('passreg').getValue()==""){
text = text+"El campo CONTRASEÑA es obligatorio \n";
ret=false;
}
if ($('passreg').getValue()!=$('pass2reg').getValue()){
text = text+"Las contraseñas no coinciden \n";
ret=false;
}
}
if ($('keyuser').getValue()==""){
text = text+"No ha introducido el código de la imagen. \n";
ret=false;
}
if (chkey=="0"){
text = text+"La Clave introducida no es correcta. \n";
ret=false;
}
if ($('privacidad').checked == false){
text = text+"Debe aceptar la politica de privacidad para seguir con el registro. \n";
}
if (text!="") {
document.location.href='#';
$('errorkey').innerHTML = "Errores Encontrados
"+text;
$('errorkey').style.display="block" ;
}
else
{
$('errorkey').innerHTML = "";
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/registro?idanonimo="+anom+"&nombre="+$('nombre').getValue()
if ($('empresa') != null) { url=url+"&empresa="+$('empresa').getValue()}
if ($('apellido1') != null) { url=url+"&apellido1="+$('apellido1').getValue()}
if ($('cif') != null) { url=url+"&cif="+$('cif').getValue()}
if ($('email') != null) { url=url+"&mail="+$('email').getValue()}
if ($('direccion') != null) { url=url+"&direccion="+$('direccion').getValue()}
if ($('apellido2') != null) { url=url+"&apellido2="+$('apellido2').getValue()}
if ($('poblacion') != null) { url=url+"&poblacion="+$('poblacion').getValue()}
if ($('cp') != null) { url=url+"&cp="+$('cp').getValue()}
if ($('provincia') != null) { url=url+"&provincia="+$('provincia').getValue()}
if ($('pais')!= null) { url=url+"&pais="+$('pais').getValue()}
if (ztipocliente != null) { url=url+"&tipocliente="+ztipocliente.getComboText();}
if (zdiafecha != null) { url=url+"&dia="+zdiafecha.getComboText();}
if (zmesfecha != null) { url=url+"&mes="+zmesfecha.getComboText();}
if (zyearfecha != null) { url=url+"&year="+zyearfecha.getComboText();}
if ($('telefono') != null) { url=url+"&telefono="+$('telefono').getValue()}
if ($('telefono') != null) { url=url+"&telefono="+$('telefono').getValue()}
if ($('mobil') != null) { url=url+"&mobil="+$('mobil').getValue()}
if ($('fax') != null) { url=url+"&fax="+$('fax').getValue()}
if ($('deseo') != null) { url=url+"&ofertas="+$('deseo').checked}
if ($('loginreg') != null) { url=url+"&login="+$('loginreg').getValue()}
if ($('passreg') != null) { url=url+"&pass="+$('passreg').getValue()}
if ($('numregistro') != null) { url=url+"&numregistro="+$('numregistro').getValue()}
if ($('web') != null) { url=url+"&web="+$('web').getValue()}
if ($('telefonoc') != null) { url=url+"&telefonoc="+$('telefonoc').getValue()}
if ($('mailc') != null) { url=url+"&mailc="+$('mailc').getValue()}
if ($('nombrer') != null) { url=url+"&nombrer="+$('nombrer').getValue()}
if ($('apellido1r') != null) { url=url+"&apellido1r="+$('apellido1r').getValue()}
if ($('cargo') != null) { url=url+"&cargo="+$('cargo').getValue()}
if ($('telefonor') != null) { url=url+"&telefonor="+$('telefonor').getValue()}
if ($('faxr') != null) { url=url+"&faxr="+$('faxr').getValue()}
if ($('mailr') != null) { url=url+"&mailr="+$('mailr').getValue()}
if ($('observaciones') != null) { url=url+"&observaciones="+$('observaciones').getValue()}
if ($('siproshop') != null) { url=url+"&siproshop="+$('siproshop').checked}
url=url+"&sid="+Math.random()
var loadialog = ""
$('OVERADDED').innerHTML = ""+loadialog+url+""
document.getElementById('SHADE').style.display="block";
document.getElementById('ADDED').style.display="block";
document.getElementById('OVERADDED').style.display="block";
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") {
$(donde).innerHTML = e.responseText ;
document.getElementById('SHADE').style.display="none";
document.getElementById('ADDED').style.display="none";
document.getElementById('OVERADDED').style.display="none";
$('login').value=$('loginreg').getValue() ;
}
}
});
}
}
function recargarCP()
{
zpoblacion.loadXML ("http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/poblacionesXMLinv?filtro="+zcp.getComboText());
new Ajax.Request("http://www.zapatoslulu.com/cgi-bin/vestibule.exe/provinciasXML?filtro="+zcp.getComboText()+'&tipo=1', { method: 'get',
onSuccess: function(e) {
if (e.responseText != "") { zprovincia.setComboText (e.responseText); }
}
});
return false;
}
function recargarpoblaciones() {
zpoblacion.loadXML ("http://www.zapatoslulu.com/cgi-bin/vestibule.exe/poblacionesXML?filtro=alme");
}
function writepoblacion(){
if ( document.getElementById('newpoblacion') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zpoblacion=new dhtmlXCombo("newpoblacion","alfa2",167);
zpoblacion.enableFilteringMode(true,"http://www.zapatoslulu.com/cgi-bin/vestibule.exe/poblacionesXML",true);
}
}
function writecp(){
if ( document.getElementById('newcp') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zcp=new dhtmlXCombo("newcp","alfa2",167);
}
}
function writetipocliente(){
if ( document.getElementById('tipocliente') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
ztipocliente=new dhtmlXCombo("tipocliente","alfa2",167);
ztipocliente.loadXML("http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/tipocliente");
ztipocliente.addOption([['1','Mayorista',''],['2','Minorista',''],['3','Exento','']]);
}
}
function writeprovincia(){
if ( document.getElementById('newprovincia') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zprovincia=new dhtmlXCombo("newprovincia","alfa2",167);
}
}
function writepais(){
if ( document.getElementById('newpais') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zpais=new dhtmlXCombo("newpais","alfa2",167);
}
}
function writediafecha(){
if ( document.getElementById('diafecha') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zdiafecha=new dhtmlXCombo("diafecha","alfa2",62);
zdiafecha.addOption([['1','1'],['2','2'],['3','3'],['4','4'],['5','5'],['6','6'],['7','7'],['8','8'],['9','9'],['10','10']]);
zdiafecha.addOption([['11','11'],['12','12'],['13','13'],['14','14'],['15','15'],['16','16'],['17','17'],['18','18'],['19','19'],['20','20']]);
zdiafecha.addOption([['21','21'],['22','22'],['23','23'],['24','24'],['25','25'],['26','26'],['27','27'],['28','28'],['29','29'],['30','30'],['31','31']]);
}
}
function writemesfecha(){
if ( document.getElementById('mesfecha') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zmesfecha=new dhtmlXCombo("mesfecha","alfa2",62);
zmesfecha.loadXML("http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/meses");
}
}
function writeyearfecha(){
if ( document.getElementById('yearfecha') != null ) {
window.dhx_globalImgPath="http://www.zapatoslulu.com/imgShop/";
zyearfecha=new dhtmlXCombo("yearfecha","alfa2",62);
zyearfecha.loadXML("http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/years");
}
}
function recargarmenus(){
//recargarmenu('submenu','submenu');
//recargarmenu('menu','menutop');
//recargarmenu('menu','MENU');
}
function login(donde)
{
document.location.href='#';
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/login?idanonimo="+anom+"&login="+$('login').getValue()+"&pass="+$('pass').getValue()
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText;
if (e.responseText.indexOf("Contrase")<0) {
getsesion();
adddata();
var l = document.location.href;
var bc=l;
//Primero hemos de quitar el idsesion y el idanonimo de la lista.
if (l.indexOf("#") != -1){
var stri= l.substring(0,l.indexOf("#"));
l=stri;
}
if (l.indexOf("&idsesion=") != -1){
var stri= l.substring(0,l.indexOf("&idsesion="));
l=stri;
}
//Y luego le añadimos el nuevo
l=l+"&idsesion="+sesion+"&idanonimo="+anom;
document.location.href=l;
}
}
}
});
return false;
}
function login2(donde)
{
document.location.href='#';
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/login?idanonimo="+anom+"&login="+$('login2').getValue()+"&pass="+$('pass2').getValue()
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $('login').value = $('login2').getValue();$('pass').value = $('pass2').getValue();$(donde).innerHTML = e.responseText ;
if (e.responseText.indexOf("password")==-1) {getsesion();}
recargarmenus();
}
}
});
}
function getsesion()
{
document.location.href='#';
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/getsesion?login="+$('login').getValue()+"&pass="+$('pass').getValue()
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { sesion = e.responseText ;getdatosusuario(divuser); }
}
});
}
function getdatosusuario(donde)
{
document.location.href='#';
url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/getdatosusuario?idsesion="+sesion
if ($('login') != null) {url=url+ "&login="+$('login').getValue()+"&pass="+$('pass').getValue()}
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML=e.responseText ; recargarmenus(); adddata(); }
}
});
}
function logout(donde)
{
var loadialog = ""
$(donde).innerHTML = "
"
var l = document.location.href;
var bc=l;
//Primero hemos de quitar el idsesion y el idanonimo de la lista.
if (l.indexOf("#") != -1){
var stri= l.substring(0,l.indexOf("#"));
l=stri;
}
if (l.indexOf("&idsesion=") != -1){
var stri= l.substring(0,l.indexOf("&idsesion="));
l=stri;
}
//Y luego le añadimos el nuevo
l=l+"&idsesion=&idanonimo="+anom;
document.location.href=l;
}
function logoutusuario(donde)
{
var loadialog = ""
$(donde).innerHTML = "
"
var url="http://www.zapatoslulu.com/cgi-bin/usuarios/users.exe/logout?"
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get',
onSuccess: function(e) {
if (e.responseText != "") { $('CENTRAL').innerHTML=e.responseText ; recargarmenus(); }
}
});
quitardata();
var l = document.location.href;
var bc=l;
//Primero hemos de quitar el idsesion y el idanonimo de la lista.
if (l.indexOf("#") != -1){
var stri= l.substring(0,l.indexOf("#"));
l=stri;
}
if (l.indexOf("&idsesion=") != -1){
var stri= l.substring(0,l.indexOf("&idsesion="));
l=stri;
}
//Y luego le añadimos el nuevo
l=l+"&idsesion=&idanonimo="+anom;
document.location.href=l;
}
function writecalendar()
{
document.write(getCalendarStyles());
var cfecha = new CalendarPopup("divfecha");
cfecha.setTodayText("Hoy");
cfecha.setWeekStartDay(1);
cfecha.setMonthNames("Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre");
cfecha.setMonthAbbreviations("Ene","Feb","Mar","Abr","May","Jun","Jul","Ago","Sep","Oct","Nov","Dic");
cfecha.setDayHeaders("D","L","M","M","J","V","S");
}
function setproducto(donde,cat,subcat,pagina,idses,idanon){
document.location.href='#';
//var loadialog = ""
//$('CENTRAL').innerHTML = "prueba";
var total = document.getElementsByName("sublp_"+donde);
cerrartodomenuprincipal();
for (var i = 0; i 0 )) {
addcarro(id,idsesion,idanonimo);
document.getElementById('SHADE').style.display="block";
document.getElementById('ADDED').style.display="block";
document.getElementById('OVERADDED').style.display="block";
document.location.href='#';
}
else
{
alert('La Cantidad solo puede ser un numero entero mayor de 0/ The Quantity must be an Integer Value and greater than 0');
}
return false;
}
function eliminararticulo(id,idsesion,idanonimo) {
document.getElementById('OVERADDED').style.display="block";
document.getElementById('ADDED').style.display="block";
document.getElementById('SHADE').style.display="block";
document.getElementById('OVERADDED').innerHTML="
¿Esta seguro de querer eliminar el articulo del carro?
"
document.location.href='#';
return false;
}
function popprint(idses,idanon,numped){
window.open('http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/popprint?idanonimo='+idanon+'&idsesion='+idses+'&numped='+numped,'','width=650,height=500,scrollbars=yes')
}
function comprobarMAIL(str)
{
var at="@"
var dot="."
var lat=str.indexOf(at)
var lstr=str.length
var ldot=str.indexOf(dot)
if (str.indexOf(at)==-1) return false
if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr) return false
if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr) return false
if (str.indexOf(at,(lat+1))!=-1) return false
if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot) return false
if (str.indexOf(dot,(lat+2))==-1) return false
if (str.indexOf(" ")!=-1) return false
return true
}
function adddata() {
if (anom!="") {
var l;
urlbase= "localhost/v6stand"
for (x=1; x<=document.getElementsByTagName("a").length; x++) {
l=document.getElementsByTagName("a")[x-1].href;
var bc=l;
//Primero hemos de quitar el idsesion y el idanonimo de la lista.
if (l.indexOf("&idsesion=") != -1){
var stri= l.substring(0,l.indexOf("&idsesion="));
l=stri;
}
//Y luego le añadimos el nuevo
if ( (l.indexOf("vestibule.")!= -1) || (l.indexOf("VESTIBULE.")!= -1) ){ document.getElementsByTagName("a")[x-1].href = l+"&idsesion="+sesion+"&idanonimo="+anom; }
if (bc.indexOf("#") != -1) {document.getElementsByTagName("a")[x-1].href=document.getElementsByTagName("a")[x-1].href+"#"}
}
}
}
function quitardata() {
var l;
urlbase= "localhost/v6stand"
for (x=1; x<=document.getElementsByTagName("a").length; x++) {
l=document.getElementsByTagName("a")[x-1].href;
var bc=l;
if (l.indexOf("&idsesion=") != -1){
var stri= l.substring(0,l.indexOf("&idsesion="));
l=stri;
}
if ( (bc.indexOf("&idsesion=") != -1)){document.getElementsByTagName("a")[x-1].href = l+"&idsesion=&idanonimo="+anom; }
if (bc.indexOf("#") != -1) {document.getElementsByTagName("a")[x-1].href=document.getElementsByTagName("a")[x-1].href+"#"}
}
}
function showbuscador(donde,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/buscador?idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function finalizar(donde,idses,idanon,numped)
{
var loadialog = ""
$(donde).innerHTML = "
' +e.responseText; igualar();}
}
});
}
function shownovedades(donde,idses,idanon)
{
var loadialog = ""
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/novedades?idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = $(donde).innerHTML+e.responseText; igualar2();}
}
});
}
function igualar(){
maxh=0;
for (x=1; x<=document.getElementsByTagName("div").length; x++) {
l = document.getElementsByTagName("div")[x-1].name;
if (l == "lproddes") {
if (maxh"
loadialog = loadialog + ""
loadialog = loadialog + ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/detallecarro?idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText ;}
}
});
}
function showdetalleproducto(donde,id,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/detalleproducto?idsesion="+sesion+"&idanonimo="+idanon+"&id="+id
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function showlistaproductos(donde,que,cate,subcat,pagina,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/listaproductos?familia="+que+"&categoria="+cate+"&subcategoria="+subcat+"&pagina="+pagina+"&idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function showmenutienda(donde,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/menutienda?idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function showmenutoptienda(donde,idses,idanon)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/menutoptienda?idsesion="+sesion+"&idanonimo="+idanon
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: true,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText; }
}
});
}
function showprint(donde,idses,idanon,numped)
{
var loadialog = ""
$(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/detalleimpresion?idanonimo="+idanon+"&numped="+numped
url=url+"&sid="+Math.random()
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") { $(donde).innerHTML = e.responseText ;}
}
});
}
function modcarro(donde,idprod,cantidad,idses,idanon)
{
var perm = 1;
if (cantidad == "0") {
if ($('nuevacantidad')!= null) {
if ($('nuevacantidad').value == "") {
perm=0;
alert('Debes indicar una cantidad para poder modificarla\nYou must enter a quantity to modify it');
}
else
{
if ( (isInteger($('nuevacantidad').getValue())) && ($('nuevacantidad').getValue() != "") && (parseInt($('nuevacantidad').getValue())>0 ) ){permm=1;}
else
{
perm=0;
alert('La Cantidad no puede ser decimal mayor de 0\nThe quantity cannot be a decimal value greater than 0');
}
}
}
}
if (perm==1) {
var loadialog = ""
// $(donde).innerHTML = "
"+loadialog+"
"
url="http://www.zapatoslulu.com/cgi-bin/v5shop/v5shop.exe/modcarro?id="+idprod+"&idsesion="+sesion+"&idanonimo="+idanon
if (cantidad != "0") {url=url+"&cantidad="+cantidad+"&sid="+Math.random()}
else
{
if ($('nuevacantidad')!= null) { url=url+"&cantidad="+$('nuevacantidad').value+"&sid="+Math.random() }
}
$(donde).innerHTML =url;
new Ajax.Request(url, { method: 'get', asynchronous: false,
onSuccess: function(e) {
if (e.responseText != "") {
showcarro(divcarro,sesion,idanon);
showdetallecarro(donde,sesion,idanon);
document.getElementById('SHADE').style.display="none";
document.getElementById('ADDED').style.display="none";
document.getElementById('OVERADDED').style.display="none";
}
}
});
}
}
function popmodcarro(donde,idprod,nombre,cantidad,idses,idanon)
{
document.getElementById('SHADE').style.display="block";
document.getElementById('ADDED').style.display="block";
document.getElementById('OVERADDED').style.display="block";
$('OVERADDED').innerHTML="