var im_up = new Array;
var im_down = new Array;
var im_se = new Array;
var im_gl = new Array;
var actual = new Array;


function gorny() {
  document.write('<table border="0" width="760" cellspacing="0" cellpadding="0"><tr style="padding-top: 2"><td width="680"><img border="0" src="menu/gornyb.gif" width="680" height="80"></td>');
  document.write('</center><center><td width="80"><img border="0" src="menu/m1g.gif" name="obraz" width="80" height="80"></td></tr>');
  document.write('<tr><td width="760" colspan="2" bgcolor="#FFFFDD" height="24">');
  document.write('<a href="index.html" target="_top" onmouseover="show_down(document.g_01,0)" onmouseout="show_up(document.g_01,0)" onclick="page(0)"><img src="menu/m1n.gif" border="0" name="g_01" alt="Strona główna" width="95" height="24"></a><a href="oddzial.html" target="_top" ');
  document.write('onmouseover="show_down(document.g_02,1)" onmouseout="show_up(document.g_02,1)" onclick="page(1)"><img src="menu/m2n.gif" border="0" name="g_02" alt="Zarząd Oddzialu" width="95" height="24"></a><a href="galeria.html" target="_top" onmouseover="show_down(document.g_03,2)" ');
  document.write('onmouseout="show_up(document.g_03,2)" onclick="page(2)"><img src="menu/m3n.gif" border="0" name="g_03" alt="Galeria" width="95" height="24"></a><a href="teatr.html" target="_top" onmouseover="show_down(document.g_04,3)" onmouseout="show_up(document.g_04,3)" ');
  document.write('onclick="page(3)"><img src="menu/m4n.gif" border="0" name="g_04" alt="Pantomima, Teatr-3" width="95" height="24"></a><a href="wideo.html" target="_top" onmouseover="show_down(document.g_05,4)" onmouseout="show_up(document.g_05,4)" onclick="page(4)"><img src="menu/m5n.gif" ');
  document.write('border="0" name="g_05" alt="Warsztaty Wideofilmowe i inne" width="95" height="24"></a><a href="alfabet.html" target="_top" onmouseover="show_down(document.g_06,5)" onmouseout="show_up(document.g_06,5)" onclick="page(5)"><img src="menu/m6n.gif" border="0" name="g_06" ');
  document.write('alt="Polski Alfabet Palcowy" width="95" height="24"></a><a href="chat.html" target="_top" onmouseover="show_down(document.g_07,6)" onmouseout="show_up(document.g_07,6)" onclick="page(6)"><img src="menu/m7n.gif" border="0" name="g_07" alt="Pogaduszki internetowe" width="95" ');
  document.write('height="24"></a><a href="link.html" target="_top" onmouseover="show_down(document.g_08,7)" onmouseout="show_up(document.g_08,7)" onclick="page(7)"><img src="menu/m8n.gif" border="0" name="g_08" alt="Adresy, linki, e-mail" width="95" height="24"></a></td></tr>');
  document.write('<tr><td width="760" colspan="2" bgcolor="#FFFFDD" style="border-left: 1 solid #808080; border-right: 1 solid #808080; border-top: 2 solid #000080; border-bottom: 2 solid #000080">');
  if (pasek == 1)
   document.write('<iframe src="pasek1.html" width="100%" height="96" frameborder="0" scrolling="no" align="left"></iframe>')
  else
   if (pasek == 2)
    document.write('<iframe src="pasek2.html" width="100%" height="36" frameborder="0" scrolling="no" align="left"></iframe>')
   else
    if (pasek == 3)
     document.write('<iframe src="pasek3.html" width="100%" height="20" frameborder="0" scrolling="no" align="left"></iframe>')
    else
     document.write('<iframe src="pasek4.html" width="100%" height="36" frameborder="0" scrolling="no" align="left"></iframe>');
  document.write('</center></td></tr></table>');
}

function loadimages() {
 loadnew( 0, "m1", 95);
 loadnew( 1, "m2", 95);
 loadnew( 2, "m3", 95);
 loadnew( 3, "m4", 95);
 loadnew( 4, "m5", 95);
 loadnew( 5, "m6", 95);
 loadnew( 6, "m7", 95);
 loadnew( 7, "m8", 95);
 swapimage( actual, im_se[ actual ] );
 if ( actual != 8 ) document.obraz.src = im_gl[ actual ].src;
}

function loadnew( n, name, x) {
 im_up[n] = new Image(x,24);
 im_down[n] = new Image(x,24);
 im_se[n] = new Image(x,24);
 im_gl[n] = new Image(80,80);
 im_up[n].src = "menu/"+name+"n.gif";
 im_down[n].src = "menu/"+name+"a.gif";
 im_se[n].src = "menu/"+name+"w.gif";
 im_gl[n].src = "menu/"+name+"g.gif";
}

function show_down( object, x ) {
 if ( x != actual )
  if ( typeof( im_down[x] ) != 'undefined' ) {
   object.src = im_down[x].src;
   if (x == 8) 
    document.obraz.src = im_gl[0].src
   else 
    document.obraz.src = im_gl[x].src
  }
}

function show_up( object, x ) {
 if ( x != actual )
  if ( typeof( im_up[x] ) != 'undefined' ) {
   object.src = im_up[x].src;
   if (actual == 8) document.obraz.src = im_gl[0].src
   else document.obraz.src = im_gl[actual].src
  }
}

function page(loc) {
 if (actual == loc) return;
 swapimage( actual, im_up[ actual ] );
 actual = loc;
 swapimage( actual, im_se[ actual ] );
 document.obraz.src = im_gl[ actual ].src;
}

function redraw() {
 swapimage( actual, im_se[ actual ] );
 if (actual == 8) document.obraz.src = im_gl[0].src
 else document.obraz.src = im_gl[actual].src;
}

function swapimage( x, src ) {
 if ( typeof( src ) != 'undefined' )
  switch ( x ) {
   case 0: if ( typeof( document.g_01 ) != 'undefined' ) document.g_01.src = src.src;
    break;
   case 1: if ( typeof( document.g_02 ) != 'undefined' ) document.g_02.src = src.src;
    break;
   case 2: if ( typeof( document.g_03 ) != 'undefined' ) document.g_03.src = src.src;
    break;
   case 3: if ( typeof( document.g_04 ) != 'undefined' ) document.g_04.src = src.src;
    break;
   case 4: if ( typeof( document.g_05 ) != 'undefined' ) document.g_05.src = src.src;
    break;
   case 5: if ( typeof( document.g_06 ) != 'undefined' ) document.g_06.src = src.src;
    break;
   case 6: if ( typeof( document.g_07 ) != 'undefined' ) document.g_07.src = src.src;
    break;
   case 7: if ( typeof( document.g_08 ) != 'undefined' ) document.g_08.src = src.src;
    break;
  }
}

function dolny() {
 document.write('<table border="0" width="750" cellspacing="0" cellpadding="0"><tr><td width="750" height="24" colspan="3" align="center" style="border-bottom: 2 solid #C0C0C0; border-top: 2 solid #C0C0C0; padding-top: 2; padding-bottom: 2" bgcolor="#dddddd">');
 document.write('<p class="tekst1"><font color="#ffffff">');
 document.write('<a class="przycisk" href="JavaScript:history.back()" target="_top">&nbsp;<b>Powrót</b>&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="index.html" target="_top">&nbsp;Strona główna&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="oddzial.html" target="_top">&nbsp;Zarząd Oddziału&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="galeria.html" target="_top">&nbsp;Galeria&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="wideo.html" target="_top">&nbsp;Wideo&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="teatr.html" target="_top">&nbsp;Teatr&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="alfabet.html" target="_top">&nbsp;Alfabet palcowy&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="chat.html" target="_top">&nbsp;Chat&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="link.html" target="_top">&nbsp;Adresy, linki&nbsp;</a>');
 document.write('&nbsp;&nbsp;<a class="przycisk" href="JavaScript:history.back()" target="_top">&nbsp;<b>Powrót</b>&nbsp;</a></font></td></tr>');
 document.write('<tr><td width="118" class="teksta1"><p align="center"><font color="#808080">&nbsp;<a target=_top href="http://stat.4u.pl/?olasek"><br>');
 document.write('<img src="http://adstat.4u.pl/s4u.gif" border="0"></a><script language="JavaScript" type="text/javascript" src="http://adstat.4u.pl/s.js?olasek"></script>');
 s4uext=s4upl();
 document.write('<img src=\"http://stat.4u.pl/cgi-bin/s.cgi?i=olasek"+s4uext+"\" width=1 height=1><noscript><img src="http://stat.4u.pl/cgi-bin/s.cgi?i=olasek&r=ns" width="1" height="1"></noscript><br>&nbsp;</font></p></td>');
 document.write('<td width="167" align="center" class="teksta1"><font color="#808080">Copyright and designed&nbsp;<br>by Olgierd Koczorowski <a href="mailto:okoczor@poczta.onet.pl">Olas</a><br>&copy; 1997-2007</font></td>');
 document.write('<td width="459" class="teksta1"><table border="0" width="100%" cellspacing="0" cellpadding="0"><tr>');
 document.write('<td width="33%" class="teksta1" style="padding-right: 2; padding-top: 2; padding-bottom: 2" valign="top" align="right"><p align="center"><font color="#808080">Kopiowanie i wykorzystanie jakichkolwiek elementów strony&nbsp;<br>bez zgody autora jest zabronione.<br>');
 aktualizacja();
 document.write('</font></p></td></tr></table></td></tr><tr><td width="744" class="teksta1" colspan="3" style="padding-top: 2; padding-bottom: 3">');
 document.write('<table border="0" width="100%" cellspacing="0" cellpadding="0"><tr>');
 document.write('<td width="22%" class="teksta1" valign="top" align="right"><font color="#808080">Strona sponsorowana przez:&nbsp;</font></td><td width="78%" class="teksta1"><font color="#808080">Państwowy Fundusz Rehabilitacji Osób Niepełnosprawnych Oddział Zachodniopomorski,&nbsp;Urząd Miasta w Szczecinie.</font></td>');
 document.write('</tr></table></td></tr></table>');
 //document.body.style.filter='progid:DXImageTransform.Microsoft.BasicImage(grayScale=1)';
}

function s4upl() {
 return "&r=er";
}

function initArray() {
 this.length = initArray.arguments.length
 for (var i=0; i< this.length; i++)
  this[i+1] = initArray.arguments[i]
}
// end initArray.

function aktualizacja() {
 var DOWArray = new initArray("niedziela", "poniedziałek", "wtorek", "środa", "czwartek", "piątek", "sobota");
 var MOYArray = new initArray("stycznia", "lutego", "marca", "kwietnia", "maja", "czerwca", "lipca", "sierpnia","września", "października", "listopada", "grudnia");
 var LastModDate = new Date(document.lastModified);
 document.write("Aktualizacja strony: ");
 document.write(DOWArray[(LastModDate.getDay()+1)],", ");
 document.write(LastModDate.getDate()," ");
 document.write(MOYArray[(LastModDate.getMonth()+1)]," ");
 document.write(LastModDate.getFullYear(),",");
 document.write(" ","g.");
 document.write(" ");
 if ((LastModDate.getHours())<10)
  document.write("0",(LastModDate.getHours()),":")
 else
  document.write((LastModDate.getHours()),":");
 if ((LastModDate.getMinutes())<10)
  document.write("0",(LastModDate.getMinutes()),".")
 else
  document.write((LastModDate.getMinutes()),".");
}

function Miesiace() {
 this.IleDni=new Array("", 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31);
 this.Nazwa=new Array("", "Stycznia", "Lutego", "Marca", "Kwietnia", "Maja", "Czerwca", "Lipca", "Sierpnia", "Września", "Października", "Listopada", "Grudnia")
 this.Dzien=new Array("", "Pn", "Wt", "Śr", "Cz", "Pt", "Sb", "Nd");
}

function Kalendarz() {
 Kolumna=0;
 nTydzien=Teraz1.getDay(Teraz1.setDate(1));
 nTydzien=(nTydzien==0 ? 7 : nTydzien)
 Rok=Teraz.getYear()+"";
 Rok=20+""+Rok.substring(Rok.length-2,Rok.length);
 if (Rok%4==0) Czas.IleDni[2]=29;
 document.write('<TABLE BORDER="0" CELLPADDING="2" CELLSPACING="0" style="font-size: 8pt;">');
 document.write('<TR><TH COLSPAN="7"><NOBR><br><FONT COLOR="#000000">'+Teraz.getDate()+"&nbsp;"+Czas.Nazwa[Teraz.getMonth()+1]+"&nbsp;"+Rok+'</FONT></NOBR></TH></TR><TR>');
 for (i=1; i<=7; i++) 
  document.write('<TH><FONT COLOR="#007AB9">'+Czas.Dzien[i]+"</FONT></TH>");
 document.write("</TR><TR>");
 for (i=1; i<nTydzien; i++) {
  document.write("<TD></TD>");
  Kolumna++;
 }
 for (i=1; i<=Czas.IleDni[Teraz.getMonth()+1]; i++) {
  document.write('<TD align="right"');
  if (i==Teraz.getDate()) document.write(' BGCOLOR="#FFCC50"');
  if (Kolumna==6) document.write(' BGCOLOR="#FF8030"');
  document.write("><I>"+i+"</I></TD>");
  Kolumna++;
  if (Kolumna==7) {
   document.write("</TR><TR>");
   Kolumna=0;
  }
 }
 document.write("</TR></TABLE>");
}

function zmiana() {
 document.images.photoslider.src=photos[which];
 document.rotater.podpis.value=podpisy[which];
 document.rotater.podpis1.value=podpisy1[which];
 document.images.miniat.src=photosm[which];
 if (which>0) {
  document.images.miniatp1.src=czeka;
  document.images.miniatp1.src=photosm[which-1]
  }
 else
  document.images.miniatp1.src=pusty;
 if (which-1>0) {
  document.images.miniatp2.src=czeka;
  document.images.miniatp2.src=photosm[which-2]
  }
 else 
  document.images.miniatp2.src=pusty;
 if (which-2>0) {
  document.images.miniatp3.src=czeka;
  document.images.miniatp3.src=photosm[which-3]
  }
 else
  document.images.miniatp3.src=pusty;
 if (which+1<ilosc) {
  document.images.miniatn1.src=czeka;
  document.images.miniatn1.src=photosm[which+1]
  }
 else
  document.images.miniatn1.src=pusty;
 if (which+2<ilosc) {
  document.images.miniatn2.src=czeka;
  document.images.miniatn2.src=photosm[which+2]
  }
 else 
  document.images.miniatn2.src=pusty;
 if (which+3<ilosc) {
  document.images.miniatn3.src=czeka;
  document.images.miniatn3.src=photosm[which+3]
  }
 else
  document.images.miniatn3.src=pusty;
}
  
function backward(){
 if (which>0){
  window.status=''
  which--
  zmiana()
 }
}

function backward2(){
 if (which>1){
  window.status=''
  which=which-2
  zmiana()
 }
}

function backward3(){
 if (which>2){
  window.status=''
  which=which-3
  zmiana()
 }
}

function backward10(){
 if (which>9){
  window.status=''
  which=which-10
  zmiana()
 }
}

function forward(){
 if (which<photos.length-1){
  which++
  zmiana()
 }
 else window.status='Koniec'
}

function forward2(){
 if (which<photos.length-2){
  which=which+2
  zmiana()
 }
 else window.status='Koniec'
}

function forward3(){
 if (which<photos.length-3){
  which=which+3
  zmiana()
 }
 else window.status='Koniec'
}

function forward10(){
 if (which<photos.length-10){
  which=which+10
  zmiana()
 }
 else window.status='Koniec'
}

function f(){
 alert("Sorry")
 return false
}

