function PathInfo(AFileName) {
//return[0] - calosc
//return[1] - sciezka
//return[2] - nazwa pliku z rozszerzeniem
//return[3] - rozszerzenie
  return AFileName.match(/^(.+(?:\\|\/))([^\\\/]+\.([^\.]+))$/);
}

var timerID = null;
var timerRunning = false;

function StopClock()
{
    if(timerRunning)
        clearTimeout(timerID)
    timerRunning = false;
}

function startClock()
{
    stopclock();
    showtime();
}

function ShowTime()
{
        var now = new Date();
        var hours = now.getHours();
        var minutes = now.getMinutes();
        var seconds = now.getSeconds();
        var timeValue = " " + ((hours > 24) ? hours - 24 : hours);
        timeValue  += ((minutes < 10) ? ":0" : ":") + minutes;
        timeValue  += ((seconds < 10) ? ":0" : ":") + seconds;
        document.clock.face.value = timeValue;
        timerID = setTimeout("showtime()",1000);
        timerRunning = true;
}

function SlideMessage(){
        if (curmsg<messages.length-1)
        curmsg++
        else
        curmsg=0
        document.slideshow[0].value=messages[curmsg]
        setTimeout("slidemessage()",8000)
}

function AssignImg(AImgId, AImgFile, AMap) {
  var im;
  im=document.getElementById(AImgId);
  im.src=AImgFile;
  if ((AMap == undefined)) AMap = '';
  im.useMap = AMap;
}

function t(v,e,t){
  if(!v.title||!document.createElement)return 
  t=document.createElement("div")
  t.move=function(e){
    e=e||event
    t.style.left=e.clientX+15+"px"
    t.style.top=e.clientY+22+"px"
  }
  t.hide=function(x){
    v.title=t.innerHTML
    if(x=document.getElementById("tooltip")) document.body.removeChild(x)
  }
  t.move(e);
  t.id="tooltip"
  t.innerHTML=v.title;v.title=""
  document.body.appendChild(t)
  v.onmouseout=t.hide
  v.onmousemove=t.move
}
