function openImg(url,w,h) { w = w+20; h = h+20; window.open(url,'Fotogalerie','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width='+w+',height='+h+',top=0,left=0'); } function changePageSize(thisForm) { if (isNaN(thisForm.pageSize.value)) return; if (thisForm.pageSize.value=="") return; if (thisForm.pageSize.value<0) return; thisForm.pageSize.value = parseInt(thisForm.pageSize.value); thisForm.submit(); } function changePageNumber(thisForm,pageNumber) { if (isNaN(pageNumber)) return; if (pageNumber=="") return; if (pageNumber<0) return; thisForm.pageNumber.value = parseInt(pageNumber)-1; thisForm.submit(); } function calculate(theForm) { calculValue = 0; for (i=2 ; i < theForm.elements.length-3 ; i=i+2) calculValue = calculValue + (theForm.elements[i].value * theForm.elements[i+1].value) ; if (!isNaN(calculValue)) { if (calculValue>=0) theForm.total.value = calculValue; } } function Tour(theForm) { if (theForm.total.value==0) { alert("Vyplňte prosím objednavku!"); return; } theForm.submit(); } function TourOrderCustomer(thisForm) { if (thisForm.__customer_firstName.value=="") { alert("Zadejte prosím Vaše jméno!"); thisForm.__customer_firstName.focus(); return; } if (thisForm.__customer_lastName.value=="") { alert("Zadejte prosím Vaše příjmení!"); thisForm.__customer_lastName.focus(); return; } if (thisForm.__customer_nativeNum.value=="") { alert("Zadejte prosím Vaše rodné číslo!"); thisForm.__customer_nativeNum.focus(); return; } if (thisForm.__customer_street.value=="") { alert("Zadejte prosím ulici!"); thisForm.__customer_street.focus(); return; } if (thisForm.__customer_streetNr.value=="") { alert("Zadejte prosím číslo popisné!"); thisForm.__customer_streetNr.focus(); return; } if (thisForm.__customer_city.value=="") { alert("Zadejte prosím město!"); thisForm.__customer_city.focus(); return; } if (thisForm.__customer_zip.value=="") { alert("Zadejte prosím PSČ!"); thisForm.__customer_zip.focus(); return; } if (thisForm.__customer_email.value!="") { mail = new RegExp("^.*[@]+.*[\.]+.{2,4}$"); if (!mail.test(thisForm.__customer_email.value)) { alert("Zadejte prosím Váš e-mail ve spravném formátu!"); thisForm.__customer_email.focus(); return; } } switch(thisForm.__contactType.value) { case "TEL": if (thisForm.__customer_phone.value=="") { alert("Zadejte prosím Váš telefon!"); thisForm.__customer_phone.focus(); return; } break; case "FAX": if (thisForm.__customer_fax.value=="") { alert("Zadejte prosím Váš fax!"); thisForm.__customer_fax.focus(); return; } break; case "E-MAIL": if (thisForm.__customer_email.value=="") { alert("Zadejte prosím Váš e-mail !"); thisForm.__customer_email.focus(); return; } break; } thisForm.submit(); } function TourOrderParticipate(thisForm) { if (thisForm.__participate_firstName.value=="") { alert("Zadejte prosím jméno účastníka!"); thisForm.__participate_firstName.focus(); return; } if (thisForm.__participate_lastName.value=="") { alert("Zadejte prosím příjmení účastníka!"); thisForm.__participate_lastName.focus(); return; } if (thisForm.__participate_nativeNum.value=="") { alert("Zadejte prosím rodné číslo!"); thisForm.__participate_nativeNum.focus(); return; } if (thisForm.__participate_street.value=="") { alert("Zadejte prosím ulici!"); thisForm.__participate_street.focus(); return; } if (thisForm.__participate_streetNr.value=="") { alert("Zadejte prosím číslo popisné!"); thisForm.__participate_streetNr.focus(); return; } if (thisForm.__participate_city.value=="") { alert("Zadejte prosím město!"); thisForm.__participate_city.focus(); return; } if (thisForm.__participate_zip.value=="") { alert("Zadejte prosím PSČ!"); thisForm.__participate_zip.focus(); return; } thisForm.submit(); }