
function commitFlashObject(_obj, _container){
	_output=""
	_paramoutput=""
	_src=""
	_ver=""
	for(_cO in _obj){
		_output+=_cO+"=\""+_obj[_cO]+"\" "
		_paramoutput+="<param name="+_cO+" value=\""+_obj[_cO]+"\">";
		if(_cO=="movie")_src="src=\""+_obj[_cO]+"\"";
		if(_cO=="version")_ver=_obj[_cO];
	}
	if(_ver=="")_ver="8,0,0,0"
	ihtm="<object classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000 codebase=http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version="+_ver+" "+_output+">\n"
	ihtm+=_paramoutput+"\n"
	ihtm+="<embed "+_src+" pluginspage=http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash type=application/x-shockwave-flash "+_output+">\n";
	ihtm+="</embed>\n";
	ihtm+="</object>\n";
	document.getElementById(_container).innerHTML=ihtm	
}

function pokaz(co) {
   if (document.getElementById) jest=document.getElementById(co).style.display;
   else if (document.all) jest=document.all[co].style.display;
   if (jest=="none") {jest="block";} else {jest="none";};
   if (document.getElementById) document.getElementById(co).style.display = jest;
   else if (document.all) document.all[co].style.display = jest;
}
function pokaz_on(co) {
   jest="block";
   if (document.getElementById) document.getElementById(co).style.display = jest;
   else if (document.all) document.all[co].style.display = jest;
}
function pokaz_off(id) {
	if (document.getElementById) document.getElementById(id).style.display = "none";
   else if (document.all) document.all[id].style.display = "none";
	}

function makeHttpRequest(url, callback_function, return_xml) { 
            var http_request = false; 

            if (window.XMLHttpRequest) { // Mozilla, Safari,... 
               http_request = new XMLHttpRequest(); 
               if (http_request.overrideMimeType) { 
                  http_request.overrideMimeType('text/html'); 
               } 
            } else if (window.ActiveXObject) { // IE 
               try { 
                  http_request = new ActiveXObject("Msxml2.XMLHTTP"); 
               } catch (e) { 
                  try { 
                     http_request = new ActiveXObject("Microsoft.XMLHTTP"); 
                  } catch (e) {} 
               } 
            } 

            if (!http_request) { 
               alert('Unfortunatelly you browser doesn\'t support this feature.'); 
               return false; 
            } 
            http_request.onreadystatechange = function() { 
               if (http_request.readyState == 4) { 
                  if (http_request.status == 200) { 
                     if (return_xml) { 
                        eval(callback_function + '(http_request.responseXML)'); 
                     } else { 
                        eval(callback_function + '(http_request.responseText)'); 
                     } 
                  } else { 
                     alert('There was a problem with the request.(Code: ' + http_request.status + ')'); 
                  } 
               } 
            } 
            http_request.open('GET', url, true); 
            http_request.send(null); 
         }
         
         function markRowsInit() {
               var rows = document.getElementsByTagName('tr');
               for ( var i = 0; i < rows.length; i++ ) {
                  if ( 'podswietl' != rows[i].className.substr(0,9)) 
                     continue;
            
                  if ( navigator.appName == 'Microsoft Internet Explorer' ) {
                     rows[i].onmouseover = function() {
                        this.className += ' hover';
                     }
                     rows[i].onmouseout = function() {
                        this.className = this.className.replace( ' hover', '' );
                     }
                  }
               }
            }
            
         function wysOkna() {
            if (window.innerHeight != null)
               return window.innerHeight;
            if (document.body.clientHeight != null)
               return document.body.clientHeight;
            return (0);
         }

         function szerOkna() {
            if (window.innerWidth != null)
               return window.innerWidth;
            if (document.body.clientWidth != null)
               return document.body.clientWidth;
            return (0);
         }

         function getVPos() {
            var scrolled; //Declaring a local variable
            if (document.documentElement && document.documentElement.scrollTop) { scrolled = document.documentElement.scrollTop; } //Sniffing for IE5
            else if (document.body) { scrolled = document.body.scrollTop; } //Sniffing for IE6
            else { scrolled = window.pageYOffset; } //Sniffing for Netscape
            return scrolled; //Returning the variable
         }
      
         function ustawTop(co, ile) {
            if (document.getElementById) document.getElementById(co).style.top = ile;
            else if (document.all) document.all[co].style.top = ile;
         }

   function wypisz(source) {
      document.write(source);
   }

   function getByID(id) {
      return document.getElementById(id);
   }
 
 function getElementTop(Elem) {

		if(document.getElementById) {	
			var elem = document.getElementById(Elem);
		} else if (document.all) {
			var elem = document.all[Elem];
		}
		yPos = elem.offsetTop;
		tempEl = elem.offsetParent;
		while (tempEl != null) {
  			yPos += tempEl.offsetTop;
	  		tempEl = tempEl.offsetParent;
  		}
		return yPos;
}
