var regc; var h1; function modif() { window.location="http://www.bursetransport.ro"; return true; } function verific() { if (document.frm1.slct.checked==false) { alert("Trebuie sa fiti de acord cu termenii si conditiile pentru a trece mai departe"); return false; } return true; } function verificB() { if (document.frm2.chk1.checked==false && document.frm2.chk2.checked==false && document.frm2.chk3.checked==false && document.frm2.chk4.checked==false) return false; return true; } function verificP() { if (document.frm2.rad1[0].checked==false && document.frm2.rad1[1].checked==false) return false; return true; } function verific2() { if(verificB()==false) { alert("Trebuie sa alegeti cel putin o bursa!"); return false; } if(verificP()==false) { alert("Trebuie sa alegeti o perioada de acces!"); return false; } return true; } function showhide(layer_ref,state) { if (state == 'block') { state = 'none'; } else { state = 'block'; } if (document.layers) { //IS NETSCAPE 4 or below document.layers[layer_ref].display = state; } if (document.getElementById &&!document.all) { hza = document.getElementById(layer_ref); hza.style.display = state; } } function calculeaza2() { var nrBurse=0; var perioada=0; var s=0; var s2=0; if(document.frm2.rad1[0].checked==false && document.frm2.rad1[1].checked==false) { document.frm2.chk4.disabled=true; document.frm2.chk2.disabled=true; document.frm2.chk3.disabled=true; document.frm2.chk1.disabled=true; } else { document.frm2.chk4.disabled=false; document.frm2.chk2.disabled=false; document.frm2.chk3.disabled=false; document.frm2.chk1.disabled=false; } if(document.frm2.chk1.checked ==true){ nrBurse++;} if(document.frm2.chk2.checked ==true){ nrBurse++;} if(document.frm2.chk3.checked ==true){ nrBurse++;} if(document.frm2.chk4.checked ==true){ nrBurse++;} if(document.frm2.rad1[0].checked==true){ perioada=1;} if(document.frm2.rad1[1].checked==true){ perioada=2;} var prt=parseInt(document.frm21.prt.value); s=prt*perioada*nrBurse; s2=s; if(nrBurse==2) s=s*95/100; if(nrBurse==3) s=s*90/100; if(nrBurse==4) s=s*85/100; var htmlTxt="
Optiunile mele :

"; if(document.frm2.chk1.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor rutiere
"; else htmlTxt+="
"; if(document.frm2.chk2.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor feroviare
"; else htmlTxt+="
"; if(document.frm2.chk3.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor maritime
"; else htmlTxt+="
"; if(document.frm2.chk4.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor aeriene
"; else htmlTxt+="
"; htmlTxt+="


Perioada activa :

"; if(perioada==1) htmlTxt+="6 (sase) luni"; else if(perioada!=2) echo+="
"; else htmlTxt+="12 (doisprezece) luni"; htmlTxt+='
'; htmlTxt+="
                                                       
" ; htmlTxt+="
Total de plata :
"; htmlTxt+="
"; document.frm2.suma.value=String(s); document.frm2.suma2.value=String(s2); htmlTxt+=String(s); htmlTxt+=" RON
"; document.getElementById("div3").innerHTML =htmlTxt; } function calculeaza() { var nrBurse=0; var perioada=0; var s=0; var s2=0; if(document.frm2.chk1.checked ==true){ nrBurse++;} if(document.frm2.chk2.checked ==true){ nrBurse++;} if(document.frm2.chk3.checked ==true){ nrBurse++;} if(document.frm2.chk4.checked ==true){ nrBurse++;} if(document.frm2.rad1[0].checked==true){ perioada=1;} if(document.frm2.rad1[1].checked==true){ perioada=2;} if(verificB()==true && verificP()==true) { var prt=parseInt(document.frm21.prt.value); s=prt*perioada*nrBurse; s2=s; if(nrBurse==2) s=s*95/100; if(nrBurse==3) s=s*90/100; if(nrBurse==4) s=s*85/100; var htmlTxt="
Optiunile mele :

"; if(document.frm2.chk1.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor rutiere
"; else htmlTxt+="
"; if(document.frm2.chk2.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor feroviare
"; else htmlTxt+="
"; if(document.frm2.chk3.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor maritime
"; else htmlTxt+="
"; if(document.frm2.chk4.checked ==true) htmlTxt+="
• Acces pe bursa transporturilor aeriene
"; else htmlTxt+="
"; htmlTxt+="


Perioada activa :

"; if(perioada==1) htmlTxt+="6 (sase) luni"; else if(perioada!=2) echo+="
"; else htmlTxt+="12 (doisprezece) luni"; htmlTxt+='
'; htmlTxt+="
                                                       
" ; htmlTxt+="
Total de plata :
"; htmlTxt+="
"; document.frm2.suma.value=String(s); document.frm2.suma2.value=String(s2); htmlTxt+=String(s); htmlTxt+=" RON
"; document.getElementById("div3").innerHTML =htmlTxt; } else { var htmlTxt="
Optiunile mele :





"; htmlTxt+="

Perioada activa :



"; htmlTxt+="
                                                       
" ; htmlTxt+="
Total de plata :


"; document.getElementById("div3").innerHTML =htmlTxt; } } function chgTara() { if(document.frm3.loc.value!="RO") { regc=document.frm3.regc.value; document.frm3.regc.value=" "; document.frm3.regc.disabled=true; } else { document.frm3.regc.disabled=false; document.frm3.regc.value=regc; } } function trim(s) { var temp = s; return temp.replace(/^\s+/,'').replace(/\s+$/,''); } function isValidEmail(parmValue) { var rex = new RegExp("^[\\w\\+-]+(\\.[\\w\\+-]+)?@((\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3})\|([\\w\\+-]+\\.[a-zA-Z]{2,}))$"); var pos = parmValue.search(rex); if (pos < 0) { return false; } else { return true; } } function verificaFrm3() { return true; } function abnr(uid, cd) { window.open("./abonare.php?uid="+uid+"&cd="+cd,"abonare2","width=350,height=200"); } function opnCont() { window.open("./cont.php","cont", "width=350,height=200,status=yes"); } function opnCont2(uid) { window.open("./dcont.php"+"?uid="+uid,"cont", "width=450,height=650,status=yes"); } function opnPass() { if(trim(document.frmlg.user.value)=="") { alert("Trebuie sa introduceti un nume de utilizator!"); } else { document.frmlg.op.value="pass"; document.frmlg.submit(); } } function lgnSbm() { if(verifylgn()) document.frmlg.submit(); } function verifylgn() { if(trim(document.frmlg.user.value)=="") { alert("Nu ati introdus un nume de utilizator!"); return false; } if(trim(document.frmlg.pass.value)=="") { alert("Nu ati introdus parola!"); return false; } return true; } function chgpass() { if(verifychgpass()) document.frm_chg_pass.submit(); } function verifychgpass() { if(trim(document.frm_chg_pass.pass1.value)=="") { alert("Nu ati introdus parola actuala!"); return false; } if(trim(document.frm_chg_pass.pass2.value)=="") { alert("Nu ati introdus noua parola!"); return false; } if(trim(document.frm_chg_pass.pass3.value)=="") { alert("Nu ati confirmat noua parola!"); return false; } if(document.frm_chg_pass.pass2.value!=document.frm_chg_pass.pass3.value) { alert("Nu ati introdus aceasi parola!"); return false; } return true; } function modMail() { window.open("./chg_mail.php","cont", "width=300,height=120"); } function modInfo() { window.open("./chg_info.php","cont", "width=350,height=700"); } function opnFirma(Id) { window.open("./afis_firma.php?uid="+Id,"Datefirma2", "width=400,height=550"); } function opnFirma2(Id,Id2) { window.open("./afis_firma.php?uid="+Id+"&mid="+Id2,"Datefirma", "width=500,height=650,scrollbars=1"); } function marfuriSbm() { if(verifymarfuriSbm()) document.frm_marfuri.submit(); } function verifymarfuriSbm() { var k=0; if(trim(document.frm_marfuri.Ploc.value)=="") { alert("Nu ati introdus o localitate de plecare!"); return false; } if(trim(document.frm_marfuri.Ptara.value)=="") { alert("Nu ati introdus o tara de plecare!"); return false; } if(trim(document.frm_marfuri.Sloc.value)=="") { alert("Nu ati introdus o localitate de sosire!"); return false; } if(trim(document.frm_marfuri.Stara.value)=="") { alert("Nu ati introdus o tara de sosire!"); return false; } if(trim(document.frm_marfuri.Ian.value)=="") { alert("Nu ati introdus anul incarcarii!"); return false; } if(trim(document.frm_marfuri.Dan.value)=="") { alert("Nu ati introdus anul descarcarii!"); return false; } if(trim(document.frm_marfuri.Mtip.value)=="") { alert("Nu ati introdus tipul de marfa!"); return false; } if(trim(document.frm_marfuri.Mcant.value)=="") { alert("Nu ati introdus cantitatea de marfa!"); return false; } if(trim(document.frm_marfuri.Aan.value)=="") { alert("Nu ati introdus anul din care anuntul devine valabil!"); return false; } if(trim(document.frm_marfuri.Psuma.value)=="") { alert("Nu ati introdus pretul!"); return false; } if(trim(document.frm_marfuri.Cnume.value)=="") { alert("Nu ati introdus o persoana de contact!"); return false; } if(trim(document.frm_marfuri.Ctel1.value)=="") { alert("Nu ati introdus un numar de telefon al persoanei de contact!"); return false; } if(parseInt(document.frm_marfuri.Dan.value)=25) { alert("Ati introdus un cuvant mai lung de 25 de caractere. Nu aveti voie!"); return false; } } return true; } function vrf_agr() { if(document.frm_agr.agr.checked==false) { alert("Nu ati bifat casuta prin care sunteti de acord cu termenii si conditiile impuse!"); return false; } if(document.frm_add_inc.tip[0].checked==true) showhide("iplt","none"); if(document.frm_add_inc.tip[1].checked==true) showhide("iplt","block"); return true; } function vrf_slct() { if(document.frm_add_inc.tip[0].checked==false && document.frm_add_inc.tip[1].checked==false) { alert("Trebuie sa selectati un tip de incident!"); return false; } else { if(document.frm_add_inc.tip[0].checked==true) { if(trim(document.frm_add_inc.suma.value)=="") { alert("Trebuie sa introduceti suma de incasat!"); return false; } if(trim(document.frm_add_inc.data.value)=="") { alert("Trebuie sa introduceti data scadenta!"); return false; } return true; } } return true; } function add_box() { if(h1==0) { h1=1; showhide("iplt","none"); } else { h1=1; showhide("iplt","block"); } } function vrf_3() { if(vrf_agr() && vrf_slct()==true) { document.frm_add_inc.submit() } } function vrfPass2() { if(trim(document.frmpass2.pass.value)=="") { alert("Nu ati introdus o parola!"); return false; } return true; } function hd() { h1=0; showhide("iplt","block"); return true; } function add_com(id) { window.open("./add_com.php?uid="+id,"Adaugacomentariu", "width=350,height=350"); } function inchideinc(id) { window.open("./close_inc.php?uid="+id,"Inchideincident", "width=450,height=350"); } function detinc(id) { window.open("./det_incident.php?uid="+id,"Detaliiincident", "width=350,height=650,scrollbars=1"); } function opnterms() { window.open("./termeni.php","Termenisiconditii", "width=550,height=750,scrollbars=1"); } function sndmail(mail) { window.open("./snd_mail.php?mail="+mail,"Trimitemail", "width=350,height=270"); } function vrfcontact() { if(trim(document.contact.nume.value)=="") { alert("NU ati introdus numele dumneavoastra!"); return false; } if(trim(document.contact.mail.value)=="") { alert("NU ati introdus o adresa de e-mail!"); return false; } if(trim(document.contact.txt.value)=="") { alert("NU ati introdus intrebarea dumneavoastra!"); return false; } return true; } function modplus1() { htmlTxt1=""; var n=0; var m=0; var i=0; var prt1=parseInt(document.frm_plus.prt1.value); var perioada1=parseInt(document.frm_plus.perioada1.value); var perioada2=0; var sb2=0; var sb1=0; var tot=0; if(document.frm_plus.br.checked==true) { n++; htmlTxt1+="    •Bursa transporturilor rutiere
"; } if(document.frm_plus.bf.checked==true) { n++; htmlTxt1+="    •Bursa transporturilor feroviare
"; } if(document.frm_plus.ba.checked==true) { n++; htmlTxt1+="    •Bursa transporturilor aeriene
"; } if(document.frm_plus.bm.checked==true) { n++; htmlTxt1+="    •Bursa transporturilor maritime
"; } if(n==0) htmlTxt1="



"; else for(i=1; i<=4-n; i++) htmlTxt1+="
"; if(n!=0) { x=prt1*n*perioada1/6; x=Math.round(x*10)/10; sb1=x; document.frm_plus.sub1.value=String(x); htmlTxt2="Subtotal de plata 1 : "+String(x)+" lei"; } else { htmlTxt2="Subtotal de plata 1 : "; document.frm_plus.sub1.value=""; } document.getElementById("abnplus1").innerHTML =htmlTxt1; document.getElementById("abnplus2").innerHTML =htmlTxt2; n=0; if(document.frm_plus.p[0].checked==true) { htmlTxt3="6 luni
"; htmlTxt4="Data expirarii : "+document.frm_plus.dataexp11.value; htmlTxt5=document.frm_plus.dataexp1.value+" - "+document.frm_plus.dataexp11.value; perioada2=6; m=1; } else { if(document.frm_plus.p[1].checked==true) { htmlTxt3="12 luni
"; htmlTxt4="Data expirarii : "+document.frm_plus.dataexp12.value; htmlTxt5=document.frm_plus.dataexp1.value+" - "+document.frm_plus.dataexp12.value; perioada2=12; m=1; } else { htmlTxt3="
"; htmlTxt4="Data expirarii : "; htmlTxt5=document.frm_plus.dataexp1.value+" -"; perioada2=0; m=0; } } if(m==0) { document.frm_plus.br2.disabled=true; document.frm_plus.bf2.disabled=true; document.frm_plus.ba2.disabled=true; document.frm_plus.bm2.disabled=true; } else { document.frm_plus.br2.disabled=false; document.frm_plus.bf2.disabled=false; document.frm_plus.ba2.disabled=false; document.frm_plus.bm2.disabled=false; } htmlTxt6=""; if(document.frm_plus.br2.checked==true) { if((document.frm_plus.br.checked==false) && (document.frm_plus.b.value[0]=='1')) sb2=sb2+prt1*(perioada1+perioada2)/6; else sb2=sb2+prt1*perioada2/6; n++; htmlTxt6+="    •Bursa transporturilor rutiere
"; } if(document.frm_plus.bf2.checked==true) { if((document.frm_plus.bf.checked==false) && (document.frm_plus.b.value[1]=='1')) sb2=sb2+prt1*(perioada1+perioada2)/6; else sb2=sb2+prt1*perioada2/6; n++; htmlTxt6+="    •Bursa transporturilor feroviare
"; } if(document.frm_plus.ba2.checked==true) { if((document.frm_plus.ba.checked==false) && (document.frm_plus.b.value[2]=='1')) sb2=sb2+prt1*(perioada1+perioada2)/6; else sb2=sb2+prt1*perioada2/6; n++; htmlTxt6+="    •Bursa transporturilor aeriene
"; } if(document.frm_plus.bm2.checked==true) { if((document.frm_plus.bm.checked==false) && (document.frm_plus.b.value[3]=='1')) sb2=sb2+prt1*(perioada1+perioada2)/6; else sb2=sb2+prt1*perioada2/6; n++; htmlTxt6+="    •Bursa transporturilor maritime
"; } if(n==0) htmlTxt6="



"; else for(i=1; i<=4-n; i++) htmlTxt6+="
"; sb2=Math.round(sb2*10)/10; tot=sb1+sb2; if(sb2!=0) { htmlTxt7="Subtotal de plata 2 : "+String(sb2)+" lei"; document.frm_plus.sub2.value=String(sb2); } else { htmlTxt7="Subtotal de plata 2 :"; document.frm_plus.sub2.value=""; } htmlTxt8="" if(tot!=0) { htmlTxt8="TOTAL DE PLATA
"+String(tot)+" lei
"; document.frm_plus.tot.value=String(tot); } else { htmlTxt8="TOTAL DE PLATA
"; document.frm_plus.tot.value=""; } document.getElementById("abnplus3").innerHTML =htmlTxt3; document.getElementById("abnplus4").innerHTML =htmlTxt4; document.getElementById("abnplus5").innerHTML =htmlTxt5; document.getElementById("abnplus6").innerHTML =htmlTxt6; document.getElementById("abnplus7").innerHTML =htmlTxt7; document.getElementById("abnplus8").innerHTML =htmlTxt8; } function majsc() { document.frm3.nume.value=document.frm3.nume.value.toUpperCase(); }