function msienapraw() {
	if (navigator.appVersion.indexOf('MSIE 7')==-1) {
		if (oo=document.getElementById('macroscope_podstrona')) oo.style.height=273;
		if (oo=document.getElementById('tlopodjedenduzy')) oo.style.height=373;
		if (oo=document.getElementById('tlopodprawy')) {
			if (location.href.indexOf('konferencje')>-1) oo.
tyle.height=373;
		}
		if (oo=document.getElementById('tlopodzakladki')) oo.style.height=373;
		if (oo=document.getElementById('tlopodzakladkiipolowki')) oo.style.height=373;
	}
}

function timeout(tt){
	
	if ((document.all) && (navigator.userAgent.indexOf('Opera')<0) && (navigator.userAgent.indexOf('Gecko')<0)) {
		msienapraw();
	}
	
	if(tt<=0){
		window.location.href='turow.php?str=1';
	}else{
		tt=tt-1;
		t=setTimeout('timeout('+tt+')',1000);		
	}
}

function OnLoad() {
	var tabs = mint.gui.CreateTabWidget("tabsContent");

	tabs.fading = true;
	tabs.activeClass = "active";
	tabs.hoverClass = "hover";
  
	tabs.AddItem("tab1", "tab1", "text", "plk.php");
	tabs.AddItem("tab2", "tab2", "text", "pe.php");
	
	mint.fx.Round("tabsContentOuter", "all", "small", true);
}

function addEvent(elm, evnt, func) {
	if (elm.addEventListener) {
	  elm.addEventListener(evnt, func, false);
	}
	else if (elm.attachEvent) {
	  elm.attachEvent('on' + evnt, function() { func(null, elm) } );
	}
}

function zdjecie_glowna()
{
	var elementy = new Array(
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/adam_wojcik.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/bartosz_bochno.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/edward_zak.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/grzegorz_ardeli.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/justin_gray.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/michal_chylinski.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/konrad_wysocki.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/krzysztof_roszyk.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/maciej_zmijewski.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/brandon_wallace.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/michael_wright.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/chris_johnson.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/pawel_turkiewicz.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/robert_witka.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/tj_thompson.jpg);\">',
	'<div id=\"kol_lewa\" style=\"background-image:url(splash_img/glowna/andrej_urlep.jpg);\">'
	);
	
	var liczba = 0;
	do
	{
		liczba = Math.random();
	}
	while (liczba >= 1);
	liczba = Math.floor(liczba * elementy.length);
	
	document.write(elementy[liczba]);
}

function zakladki() {
	document.observe('dom:loaded',function(){
		new Control.Tabs('tabs_example_three',{
			hover: true
		});
	});
}

function correctPNG()
{
	for (var i=0; i<document.images.length; i++)
	{
		var img = document.images[i]
   var imgName = img.src.toUpperCase()
   if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
   {
  var imgStyle = "display:inline-block;"
  if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle      
  var strNewHTML = "<span "
				 + " style=\"" + "width:" + img.width + "px; height:"
			+ img.height + "px;" + imgStyle + ";"
					  + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
				 + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>"
  img.outerHTML = strNewHTML
  i = i-1
	}
	}
}
window.attachEvent("onload", correctPNG);