
// ZEGAREK
var timerID = null;
var timerRunning = false;

function stopclock()
{
    if(timerRunning)
        clearTimeout(timerID)
    timerRunning = false;
}

function startclock()
{
    stopclock();
    showtime();
}

function showtime()
{
  var godzina, minuty, sekundy, dzien, licz_dzien, miesiac, dzisiaj, rok, tekst_miesiac, tekst_dzien;

  dzisiaj = new Date();
  godzina=dzisiaj.getHours();
  minuty=dzisiaj.getMinutes();
  sekundy=dzisiaj.getSeconds();

   // if (godzina < 10) {godzina="0"+godzina;}
         if (minuty < 10) {minuty="0"+minuty;}
          if (sekundy < 10) {sekundy="0"+sekundy;}

// pelnyczas=godzina+":"+minuty+":"+sekundy;
 pelnyczas=godzina+":"+minuty;

    document.clock.face.value = pelnyczas;
        // timerID = setTimeout("showtime()",1000);
    timerID = setTimeout("showtime()",10000);
    timerRunning = true;
}



var du_ba_opoznienie = 4000;                             // czas (w milisek.) pokazywania banera
var du_ba_nazwaodnosnika = "#odnosnik_duzy_baner"      // nazwa odnosnika, ktory bedzie sluzyl do zmiany banerow

var du_odnosi = 0;

/*
var du_ba_obrazek = new Array(); // dodawanie obrazkow jest analogiczne, wazne jest nadanie odpowiedniego numeru
du_ba_obrazek[0] = new du_ba_odnosnik(0,"http://www.braclowiecka.net.pl","grafika/banery/590_70/baner_konkurs.jpg", "opis alt 0", 3000 );
*/

var du_ba_pomocy;                                        // potrzebna przy setTimeout

//        wykonywana po zaladowaniu strony                    ///
function du_ba_init() {                                  
  for (licznik = 0; licznik  < document.links.length; licznik++) { // znajduje nr odnosnika na podstawie kotwicy
   if ( document.links[licznik].hash == du_ba_nazwaodnosnika )  {       // "odnosnik" to nazwa odnosnika stworzonego przez <a href="plik.roz" name="#odnosnik">costam</a>
   du_odnosi = licznik; 
   break;                                          // przerwij w momencie znalezienia 
   }
 }
du_ba_zmien(0)                                  //uruchamia funkcje zmiany banerow
}

//          stworzenie nowego obrazka wraz z odnosnikiem      //
function du_ba_odnosnik(numer, odnosnik, obraz, opis_alt, opoznienie) {
 this[numer] = new Image;
 this.odnosnik = odnosnik; 
 this.src = obraz;
 this.alt = opis_alt;
 this.opoznie = opoznienie;
}

//      zmienia obrazek na stronie i odnosnik ktory wskazuje  //
function du_ba_zmien(ktory) {                            
if ( typeof document.images["obr_duz_baner"] == "undefined" ) {
  setTimeout("du_ba_zmien("+ktory+")",1000);
  return;
}

if ( du_ba_obrazek.length <= 0 ) return;

 if ( ktory == (du_ba_obrazek.length - 1) ) du_ba_pomocy = 0;
 else du_ba_pomocy = ktory + 1;


 document.images["obr_duz_baner"].src = du_ba_obrazek[ktory].src;
 document.links[du_odnosi].href = du_ba_obrazek[ktory].odnosnik;


        op_du_ba = du_ba_obrazek[ktory].opoznie * 1000;
        // setTimeout ("du_ba_zmien(du_ba_pomocy)",du_ba_opoznienie);
setTimeout ("du_ba_zmien(du_ba_pomocy)",op_du_ba);


}

// definicje pomocniczych zmiennych
var ksw_opoznienie = 4000;                             // czas (w milisek.) pokazywania banera
var ksw_nazwaodnosnika = "#odnosnik_ksw"      // nazwa odnosnika, ktory bedzie sluzyl do zmiany banerow
var ksw_odnosi = 0;

/*
var tab_ksw_obrazek = new Array(); // dodawanie obrazkow jest analogiczne, wazne jest nadanie odpowiedniego numeru
tab_ksw_obrazek[0] = new ksw_odnosnik(0,"http://www.sklep-oikos.net.pl","grafika/banery/ksw/01_160-200.jpg", "opis alt 0", 3000 );
tab_ksw_obrazek[1] = new ksw_odnosnik(1,"http://www.sklep-oikos.net.pl","grafika/banery/ksw/02_160-200.jpg", "opis alt 0", 3000 );
*/


var ksw_pomocy;                                        // potrzebna przy setTimeout

//        wykonywana po zaladowaniu strony                    ///
function ksw_init() {                                  
  for (licznik = 0; licznik  < document.links.length; licznik++) { // znajduje nr odnosnika na podstawie kotwicy
   if ( document.links[licznik].hash == ksw_nazwaodnosnika )  {       // "odnosnik" to nazwa odnosnika stworzonego przez <a href="plik.roz" name="#odnosnik">costam</a>
   ksw_odnosi = licznik; 
   break;                                          // przerwij w momencie znalezienia 
   }
 }
ksw_zmien(0);                                  //uruchamia funkcje zmiany banerow
}

//          stworzenie nowego obrazka wraz z odnosnikiem      //
function ksw_odnosnik(numer, odnosnik, obraz, opis_alt, opoznienie) {
 this[numer] = new Image;
 this.odnosnik = odnosnik; 
 this.src = obraz;
 this.alt = opis_alt;
 this.opoznie = opoznienie;
}

//      zmienia obrazek na stronie i odnosnik ktory wskazuje  //
function ksw_zmien(ktory) {
if ( typeof document.images["obr_ksw_baner"] == "undefined" ) {
  setTimeout("ksw_zmien("+ktory+")",1000);
  return;
}
if ( tab_ksw_obrazek.length <= 0 ) return;
                            
 if ( ktory == (tab_ksw_obrazek.length - 1) ) ksw_pomocy = 0;
 else ksw_pomocy = ktory + 1;


 document.images["obr_ksw_baner"].src = tab_ksw_obrazek[ktory].src;
// document.getElementById("banner1_id").src = tab_ksw_obrazek[ktory].src;
 document.links[ksw_odnosi].href = tab_ksw_obrazek[ktory].odnosnik;
// document.getElementById("odnosnik1_id").href = tab_ksw_obrazek[ktory].odnosnik;
  
        var op_ksw = tab_ksw_obrazek[ktory].opoznie * 1000;
 // setTimeout ("ksw_zmien(ksw_pomocy)",ksw_opoznienie);
 setTimeout ("ksw_zmien(ksw_pomocy)", op_ksw );



}


// ------ zmienaiace sie okładki pisma
// definicje pomocniczych zmiennych
/*
var ok_opoznienie = 2000;                             // czas (w milisek.) pokazywania banera
var ok_nazwaodnosnika = "#odnosnik_ok"      // nazwa odnosnika, ktory bedzie sluzyl do zmiany banerow
var tab_ok_obrazek = new Array(); // dodawanie obrazkow jest analogiczne, wazne jest nadanie odpowiedniego numeru

tab_ok_obrazek[0] = new ok_odnosnik(0,"./roczniki.php?rocz=2004&mies=1&sekc=1&kate=1#spis_t","./grafika/banery/okladki/01_drwal_1_04.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[1] = new ok_odnosnik(1,"./roczniki.php?rocz=2004&mies=2&sekc=1&kate=2#spis_t","./grafika/banery/okladki/02_drwal_2_04.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[2] = new ok_odnosnik(2,"./roczniki.php?rocz=2005&mies=1&sekc=2&kate=3#spis_t","./grafika/banery/okladki/03_drwal_1_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[3] = new ok_odnosnik(3,"./roczniki.php?rocz=2005&mies=2&sekc=2&kate=4#spis_t","./grafika/banery/okladki/04_drwal_2_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[4] = new ok_odnosnik(4,"./roczniki.php?rocz=2005&mies=3&sekc=2&kate=5#spis_t","./grafika/banery/okladki/05_drwal_3_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[5] = new ok_odnosnik(5,"./roczniki.php?rocz=2005&mies=4&sekc=2&kate=7#spis_t","./grafika/banery/okladki/06_drwal_4_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[6] = new ok_odnosnik(6,"./roczniki.php?rocz=2005&mies=5&sekc=2&kate=17#spis_t","./grafika/banery/okladki/07_drwal_5_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[7] = new ok_odnosnik(7,"./roczniki.php?rocz=2005&mies=6&sekc=2&kate=20#spis_t","./grafika/banery/okladki/08_drwal_6_05.jpg", "opis alt 0", 3000 );
tab_ok_obrazek[8] = new ok_odnosnik(8,"./roczniki.php?rocz=2006&mies=1&sekc=8&kate=21#spis_t","./grafika/banery/okladki/09_drwal_1_06.jpg", "opis alt 0", 3000 );


var ok_pomocy;                                        // potrzebna przy setTimeout
function ok_init() {                                  
  for (licznik = 0; licznik  < document.links.length; licznik++) { // znajduje nr odnosnika na podstawie kotwicy
   if ( document.links[licznik].hash == ok_nazwaodnosnika )  {       // "odnosnik" to nazwa odnosnika stworzonego przez <a href="plik.roz" name="#odnosnik">costam</a>
   ok_odnosi = licznik; 
   break;                                          // przerwij w momencie znalezienia 
   }
 }
ok_zmien(0);                                  //uruchamia funkcje zmiany banerow
}

function ok_odnosnik(numer, odnosnik, obraz, opis_alt, opoznienie) {
 this[numer] = new Image;
 this.odnosnik = odnosnik; 
 this.src = obraz;
 this.alt = opis_alt;
 this.opoznie = opoznienie;
}

function ok_zmien(ktory) {
 if ( ktory == (tab_ok_obrazek.length - 1) ) ok_pomocy = 0;
 else ok_pomocy = ktory + 1;

 document.images["obr_okl_baner"].src = tab_ok_obrazek[ktory].src;
 //  document.links[ok_odnosi].href = tab_ok_obrazek[ktory].odnosnik;
 document.links[ok_odnosi].href = tab_ok_obrazek[ktory].odnosnik;
 setTimeout ("ok_zmien(ok_pomocy)",ok_opoznienie);
}
*/



/* ####################################################### */

function setPointer(theRow, thePointerColor)
{
    if (thePointerColor == '' || typeof(theRow.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = theRow.getElementsByTagName('td');
    }
    else if (typeof(theRow.cells) != 'undefined') {
        var theCells = theRow.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = thePointerColor;
    }

    return true;
}




function podswietl(gdzie, kolor)
{
    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}



function podswietl_mover(gdzie)
{
var kolor = '#B4B4B4';


    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}


function podswietl_mout(gdzie)
{
// kolor przycisków z arkusza stylów
var kolor = '#BFCEE1';
// #6087C0

    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}



function podswietl_mout_pod_menu(gdzie)
{
// kolor przycisków z arkusza stylów
var kolor = '#ABC4E5';


    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}


function podswietl_mout_pod_menu_uzy(gdzie)
{
// kolor przycisków z arkusza stylów
var kolor = '#8B4545';


    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}



function podswietl_mover_m_g(gdzie)
{
var kolor = '#ABC4E5';


    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
// theCells[c].style.background='kolor url(grafika/tlo/tlo_pas_g_01.jpg) repeat-x scroll top left'
// theCells[c].style.background='kolor'
// theCells[c].style.background=' url(grafika/tlo/tlo_pas_g_01.jpg) repeat-x scroll top left'

    }

    return true;
}


function podswietl_mout_m_g(gdzie)
{
// kolor przycisków z arkusza stylów
var kolor = '#7FA0B6';
// #6087C0

    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
         // theCells[c].style.backgroundColor = kolor;
// theCells[c].style.background='kolor url(grafika/tlo/tlo_pas_g_01.jpg) repeat-x scroll top left'
theCells[c].style.background=' url(grafika/tlo/tlo_pas_g_01.jpg) repeat-x'
// theCells[c].style.background=' url(grafika/tlo/tlo_pas_g_01.jpg) repeat-x scroll top left'

    }

    return true;
}


function podswietl_mover_m_d(gdzie)
{
var kolor = '#284E95';


    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}


function podswietl_mout_m_d(gdzie)
{
// kolor przycisków z arkusza stylów
var kolor = '#BFCEE1';
// #6087C0

    if (kolor == '' || typeof(gdzie.style) == 'undefined') {
        return false;
    }
    if (typeof(document.getElementsByTagName) != 'undefined') {
        var theCells = gdzie.getElementsByTagName('td');
    }
    else if (typeof(gdzie.cells) != 'undefined') {
        var theCells = gdzie.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    for (var c = 0; c < rowCellsCnt; c++) {
        theCells[c].style.backgroundColor = kolor;
    }

    return true;
}



/* ############### AUTOSTART ################3 */


function auto_start()
{
        startclock();

        // init();
        du_ba_init();
        ksw_init();
// ok_init();


}


// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/* ##################### zespół braci łowieckiej ##################### */
// okno do mapy
function powieksz_mapke(url, opis, nr_str) {

var width=600;
var height=450;
       // var pop=0;
nazwa_okna = new Array(5);
nazwa_okna[1]="okno_1";
nazwa_okna[2]="okno_2";
nazwa_okna[3]="okno_3";
nazwa_okna[4]="okno_4";

        // var pop = window.open(url,"Okno_",'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );
 var  pop = window.open("",nazwa_okna[nr_str],'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );
        /*
         config='toolbar=no,location=no,directories=no,status=no,menubar=no,width=200,height=150'
         config += 'scrollbars=no,resizable=no'
         pop = window.open ("","pop",config)
        */

pop.document.write('<html>');
pop.document.write('<head>');
pop.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">');
// pop.document.write('<title>[' + url +']</title>');
pop.document.write('<title> Drwal - Pismo przedsiębiorców le¶nych  - ' + opis + ' </title>');

pop.document.write('</head>');
pop.document.write('<body bgcolor=White>');
        // pop.document.write('<body>');
// #E3E3E3
// #F2E1CF

pop.document.write('<center><div style="text-align:center;">');
        // parent.Towar.document.write('</head><body link="Silver" vlink="Silver" alink="Silver">');

        pop.document.write('<script language="javascript">');
                // okno na całay ekran 
                pop.document.write('self.moveTo(0,0);');
                pop.document.write('self.resizeTo(screen.availWidth,screen.availHeight);');
                // otwiera strone
                        // pop.document.write('parent.location.href="' + url + '"');

//        pop.document.write('function doit(){');
//        pop.document.write('        if (!window.print){');
//        pop.document.write('        alert("Musisz mieć NS4.x lub IE5,\naby użyć przycisku drukowania!")');
//        pop.document.write('        return');
//        pop.document.write('        }');
//        pop.document.write('window.print()');
//        pop.document.write('}');


        pop.document.write('</');
        pop.document.write('script>');


pop.document.write('<a href="javascript:window.close()">');
// pop.document.write('<img src="'  + url +  '" alt="Mapka - kliknij aby zamkn±ć" border=1 height=531 width=591 hspace=10 vspace=10></a>');
// pop.document.write('<img src="'  + url +  '" alt="Mapka - kliknij aby zamkn±ć" border=1 height=581 width=645 hspace=10 vspace=10></a>');
pop.document.write('<img src="'  + url +  '" alt="Mapka - kliknij aby zamkn±ć" border=1 height=496 width=612 hspace=10 vspace=10></a>');


        // pop.document.write('<br><a href="javascript:doit()"><img src="grafika/print.gif" border=0 alt="Drukowanie strony"></a>');
// pop.document.write('<br><a href="javascript:window.print()"><img src="grafika/print.gif" border=0 alt="Drukowanie strony"></a>');

// pop.document.write('<a href="#" onclick="top.prawy.focus(); window.print();">Drukuj temat</a>');
// pop.document.write('<a href="#" onclick="top.nazwa_okna[nr_str].focus(); window.print();">Drukuj temat</a>');



pop.document.write('<br><br><span style="color:Black;">'+ opis +'</span><br><br>');
        // pop.document.write('<a href="javascript:window.close()">zamknij okienko</a>');
pop.document.write('<BUTTON onClick="javascript:window.close()">Zamknij okno</BUTTON>');


        // pop.document.write('<br>');
pop.document.write('<br></div></center>');

pop.document.write('</body></html>');
}

// -------- na zdjecia - konkurs

function powieksz_zdjecie(url, opis) {

var width=900;
var height=700;

       // var pop=0;
nazwa_okna = new Array(5);
nazwa_okna[1]="okno_1";
nazwa_okna[2]="okno_2";
nazwa_okna[3]="okno_3";
nazwa_okna[4]="okno_4";

        // var pop = window.open(url,"Okno_",'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );
 var  pop = window.open("",nazwa_okna[1],'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );

        /*
         config='toolbar=no,location=no,directories=no,status=no,menubar=no,width=200,height=150'
         config += 'scrollbars=no,resizable=no'
         pop = window.open ("","pop",config)
        */

pop.document.write('<html>');
pop.document.write('<head>');
pop.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">');
// pop.document.write('<title>[' + url +']</title>');
pop.document.write('<title> Ptaki Polski - ' + opis + ' </title>');
// pop.document.write('<title> Ptaki Polski </title>');

pop.document.write('</head>');
pop.document.write('<body bgcolor=#C6E2FF>');
        // pop.document.write('<body>');
// #E3E3E3
// #F2E1CF

pop.document.write('<center><div style="text-align:center;">');
        // parent.Towar.document.write('</head><body link="Silver" vlink="Silver" alink="Silver">');

        pop.document.write('<script language="javascript">');
                // okno na całay ekran 
                pop.document.write('self.moveTo(0,0);');
                pop.document.write('self.resizeTo(screen.availWidth,screen.availHeight);');
                // otwiera strone
        pop.document.write('</');
        pop.document.write('script>');

pop.document.write('<a href="javascript:window.close()">');
pop.document.write('<img src="'  + url +  '" alt="Kliknij aby zamkn±ć" border=1 hspace=3 vspace=3></a>');

pop.document.write('<br><span style="color:Black;">'+ opis +'</span><br>');
        // pop.document.write('<a href="javascript:window.close()">zamknij okienko</a>');
pop.document.write('<BUTTON onClick="javascript:window.close()">Zamknij okno</BUTTON>');

        // pop.document.write('<br>');
pop.document.write('<br></div></center>');

pop.document.write('</body></html>');
}


/*  &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& */


// Wschody i zachody Słońca iKsiężyca


// ###################3
 function wstaw_poprz_zero( minuty )
{
var text = "0";
if (minuty <= 9)
        {
        return text + minuty;
        }
return minuty;
}
// ***************


 function wsch_zach_slonca()
{
  document.write ("<td> "+ sl_godz_wsch +" <sup> ");
        if( sl_min_wsch < 10 ) document.write ("0");
  document.write (""+ sl_min_wsch +" </sup></td>");

  document.write ("<td> "+ sl_godz_zach +" <sup> ");
        if( sl_min_zach < 10 ) document.write ("0");
  document.write (""+ sl_min_zach +" </sup></td>");
}

 function wsch_zach_ksiezyca()
{
  document.write ("<td> "+ ks_godz_wsch +" <sup> ");
        if( ks_min_wsch < 10 ) document.write ("0");
  document.write (""+ ks_min_wsch +" </sup></td>");

  document.write ("<td> "+ ks_godz_zach +" <sup> ");
        if( ks_min_zach < 10 ) document.write ("0");
  document.write (""+ ks_min_zach +" </sup></td>");

}
// #############################################
// z mambo do powiekszania i zmni

var nW,nH,oH,oW;
function zoomToggle(iWideSmall,iHighSmall,iWideLarge,iHighLarge,whichImage){
oW=whichImage.style.width;oH=whichImage.style.height;
if((oW==iWideLarge)||(oH==iHighLarge)){
nW=iWideSmall;nH=iHighSmall;}else{
nW=iWideLarge;nH=iHighLarge;}
whichImage.style.width=nW;whichImage.style.height=nH;
}
 // do otwarcja formu

function skok_do_srtony(url, nr_str) {

var width=600;
var height=450;
        // var pop=0;
nazwa_okna = new Array(5);
nazwa_okna[1]="okno_1";
nazwa_okna[2]="okno_2";
nazwa_okna[3]="okno_3";
nazwa_okna[4]="okno_4";

        // var pop = window.open(url,"Okno_",'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );
 var  pop = window.open("",nazwa_okna[nr_str],'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );

        /*
         config='toolbar=no,location=no,directories=no,status=no,menubar=no,width=200,height=150'
         config += 'scrollbars=no,resizable=no'
         pop = window.open ("","pop",config)
        */
pop.document.write('<html>');
pop.document.write('<head>');
pop.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">');

        // pop.document.write('<title>Forum: Braclowiecka.net.pl [' + url +']</title>');
  //  pop.document.write('<title>Forum: Braclowiecka.net.pl</title>');

  switch(nr_str)
         {
         case 1 : 
          pop.document.write('<title>Forum: Ptaki-Polski.pl</title>');
        break;
         case 2 : 
          pop.document.write('<title>Drukuj: Ptaki-Polski.pl</title>');
        break;
         case 3 : 
          pop.document.write('<title>Używane maszyny: Ptaki-Polski.pl</title>');
        break;

         default : 
          pop.document.write('<title>Ptaki-Polski.pl</title>');
        break;
        }

pop.document.write('</head>');
pop.document.write('<body bgcolor=White>');
        // pop.document.write('<center>');
        // parent.Towar.document.write('</head><body link="Silver" vlink="Silver" alink="Silver">');
        pop.document.write('<script language="javascript">');

                // okno na całay ekran 
                pop.document.write('self.moveTo(0,0);');
                pop.document.write('self.resizeTo(screen.availWidth,screen.availHeight);');
                // otwiera strone

// var url_2 = unescape(url);

               pop.document.write('parent.location.href="' + url + '"');
        pop.document.write('</');
        pop.document.write('script>');

pop.document.write('</body></html>');
}


function drukuj(){

window.print()
}



function skok_do_zyczen(url, nr_str) {

var width=750;
var height=530;
        // var pop=0;
        // var pop = window.open(url,"Okno_",'width=' + width + ',height=' + height + ',resizable,scrollbars=yes,menubar=no' );
 var  pop = window.open("", "Okno_z",'width=' + width + ',height=' + height + ',resizable,scrollbars=no,menubar=no' );

pop.document.write('<html>');
pop.document.write('<head>');
pop.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">');

        // pop.document.write('<title>Forum: Braclowiecka.net.pl [' + url +']</title>');
  //  pop.document.write('<title>Forum: Braclowiecka.net.pl</title>');

          pop.document.write('<title>Drwal.net.pl</title>');

pop.document.write('</head>');
pop.document.write('<body bgcolor=#FFFFFF>');
        // pop.document.write('<center>');
        // parent.Towar.document.write('</head><body link="Silver" vlink="Silver" alink="Silver">');
        pop.document.write('<script language="javascript">');
                // okno na całay ekran 
//                pop.document.write('self.moveTo(0,0);');
//                pop.document.write('self.resizeTo(screen.availWidth,screen.availHeight);');
                // otwiera strone
               pop.document.write('parent.location.href="' + url + '"');
       pop.document.write('</');
       pop.document.write('script>');

pop.document.write('</body></html>');
}


/* ---------- ogloszenia ------ */

function wypel_kupon( pomin, max_l_znakow )
{
// document.oglo.z_1.value = "A";
var tel_kon = document.oglo.tel_kon.value;
var l_tel_kon = tel_kon.length;

if (l_tel_kon <= 0) tel_kon = "(??)???????"

var z_opis = document.oglo.opis.value;
z_opis = z_opis  + " Tel. " + tel_kon;

var l_znakow = z_opis.length;



document.oglo.li_znakow.value = l_znakow;

// document.oglo.z_1.value = z_opis;


if (l_znakow > max_l_znakow )
  {
  document.oglo.blad_kom.value = "ogłoszenie jest za długie !";
  return;
  }

if (l_znakow == max_l_znakow )
  {
  document.oglo.blad_kom.value = "maksymalna długo¶ć";
  }
else
  {
  document.oglo.blad_kom.value = " ";
  }


var p = pomin;

for (var i=0; i <= l_znakow; i++ )
  {
  document.oglo[p].value = z_opis.substring(i,i+1);
  p++;
  }

for ( ; i < max_l_znakow; i++ )
  {
  document.oglo[p].value = " ";
  p++;
  }



// alert('z_opis');
// alert('Nastąpiła reakcja'); 


}

// -------- funkcje ala dodawanego ogloszenia 

function copy_mejsc_kod_mej()
{
// document.oglo.z_1.value = "A";
var ztm_miejscowosc = document.form_oglo_zam.miejscowosc.value;

document.form_oglo_zam.kod_pocz_miejscowosc.value = ztm_miejscowosc;

}

function copy_mej_kod_me_pre()
{
	// document.oglo.z_1.value = "A";
var ztm_miejscowosc = document.form_pre_zam.miejscowosc.value;

document.form_pre_zam.kod_pocz_miejscowosc.value = ztm_miejscowosc;
// document.form_pre_zam.kod_pocz_miejscowosc.value = '1aaaaaa1';

}


function copy_mej_kod_me_pre_od()
{
// document.oglo.z_1.value = "A";
var ztm_miejscowosc = document.form_pre_zam.miejscowosc_od.value;

document.form_pre_zam.kod_pocz_miejscowosc_od.value = ztm_miejscowosc;

}


// rejestracja uzytkownika
function copy_mej_kod_me_reje()
{
var ztm_miejscowosc = document.form_reje.miejscowosc.value;
document.form_reje.kod_pocz_miejscowosc.value = ztm_miejscowosc;
}



// KONIEC FUNKCJI
//-->
