

var okienko = null;

function okno(link,name,x,y)
{
if (!y) var y=screen.height-100;
	if (!okienko || okienko.closed)
		{
		okienko=window.open(link,name,'directories=no, location=no, menubar=no, scrollbars=yes, status=no, toolbar=no, resizable=1, width=' + x + ', height=' + y + ', left='+(screen.width-x-30)+', top=10');
		}
	okienko.focus();
}

versOk = (((navigator.appName == "Netscape")&& 
            (parseInt(navigator.appVersion) >= 3)) ||
        
           ((navigator.appName == "Microsoft Internet Explorer")&&
            (parseInt(navigator.appVersion)>=4))
          );

	
if (versOk) 
{		



}

function rollOn(n)
{
 if (versOk)
        {
	   light=eval(n+"2.src");
           document [n].src=light;
        }
}

function rollOff(n)
{
 if (versOk)
        {
           dark=eval(n+"1.src");
           document [n].src=dark;
        }
}



function sprawdz_dane()
{
var komunikat = "";
var lokalizacja = "";
var warunek = 0;
var licznik;

if (document.dane.nazwisko.value == "" )    { komunikat = komunikat + "   - Nazwisko\n";}
if (document.dane.ulica.value == "" )    { komunikat = komunikat + "   - Ulica\n";}
if (document.dane.miasto.value == "" )    { komunikat = komunikat + "   - Miasto\n";}
if (document.dane.kod.value == "" )    { komunikat = komunikat + "   - Kod\n";}
if (document.dane.telefon.value == "" )    { komunikat = komunikat + "   - Telefon\n";}
if (document.dane.email.value == "" )    { komunikat = komunikat + "   - E-mail\n";}
if ((document.dane[8].checked == false) && (document.dane[9].checked == false) && (document.dane[10].checked == false))   { komunikat = komunikat + "   - dostarczenie przesyłki\n";}

if (komunikat == "") {
			  document.dane.submit();
			  }
    else {
      var text = " Błąd!\n Nie zostały wypełnione pola:\n\n" + komunikat + "\n  Wróć do formularza i uzupełnij dane.";
      window.alert(text);
    } //else

}


