<!--

function showokienka() {
ostate = 'visible';
if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.okienka.style.visibility = ostate");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['okienka'].visibility = ostate;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('okienka');
maxwell_smart.style.visibility = ostate;
}
}
function hideokienka() {
ostate2 = 'hidden';
if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.okienka.style.visibility = ostate2");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['okienka'].visibility = ostate2;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('okienka');
maxwell_smart.style.visibility = ostate2;
}
}



function ukazmenu() {
	document.getElementById("hmenu-cont").style.margin='30px 0 12px 0;';
	document.getElementById("sipka").innerHTML='<img src="obrazky/sipkahore.gif" width="54" height="7" alt="skri" style="cursor:pointer; border:none;" onclick="skrimenu();" />';
}
function skrimenu() {
	document.getElementById("sipka").innerHTML='<img src="obrazky/sipkadole.gif" width="54" height="7" alt="ukaz" style="cursor:pointer; border:none;" onclick="ukazmenu();" />';
	document.getElementById("hmenu-cont").style.margin='0 0 12px 0;';
}



var state2 = 'hidden';

function showhide2(layer_ref2) {

if (state2 == 'visible') {
state2 = 'hidden';
}
else {
state2 = 'visible';
}
if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all." + layer_ref2 + ".style.visibility = state");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers[layer_ref2].visibility = state2;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById(layer_ref2);
maxwell_smart.style.visibility = state2;
}
}

var statezavpri = 'hidden';
function zavpriatelia() {

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknopriatelia.style.visibility = statezavpri");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknopriatelia'].visibility = statezavpri;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('oknopriatelia');
maxwell_smart.style.visibility = statezavpri;
}
}

var statezavpos = 'hidden';
function zavposta() {

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknoposta.style.visibility = statezavpos");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknoposta'].visibility = statezavpos;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('oknoposta');
maxwell_smart.style.visibility = statezavpos;
}
}

var statezavchat = 'hidden';
function zavchat() {

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknochat.style.visibility = statezavchat");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknochat'].visibility = statezavchat;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('oknochat');
maxwell_smart.style.visibility = statezavchat;
}
}


function otvposta() {
stateotvpos = 'visible';
statezatpri2 = 'hidden';
statezatcha2 = 'hidden';

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknoposta.style.visibility = stateotvpos");
eval( "document.all.oknopriatelia.style.visibility = statezatpri2");
eval( "document.all.oknochat.style.visibility = statezatcha2");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknoposta'].visibility = stateotvpos;
document.layers['oknopriatelia'].visibility = statezatpri2;
document.layers['oknochat'].visibility = statezatcha2;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById('oknoposta');
maxwell_smart.style.visibility = stateotvpos;
maxwell_smart2 = document.getElementById('oknopriatelia');
maxwell_smart2.style.visibility = statezatpri2;
maxwell_smart3 = document.getElementById('oknochat');
maxwell_smart3.style.visibility = statezatcha2;
}
}


function otvpriatelia() {
stateotvpri = 'visible';
statezatpos2 = 'hidden';
statezatcha2 = 'hidden';

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknopriatelia.style.visibility = stateotvpri");
eval( "document.all.oknoposta.style.visibility = statezatpos2");
eval( "document.all.oknochat.style.visibility = statezatcha2");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknopriatelia'].visibility = stateotvpri;
document.layers['oknoposta'].visibility = statezatpos2;
document.layers['oknochat'].visibility = statezatcha2;
}
if (document.getElementById && !document.all) {
maxwell_smart2 = document.getElementById('oknopriatelia');
maxwell_smart2.style.visibility = stateotvpri;
maxwell_smart = document.getElementById('oknoposta');
maxwell_smart.style.visibility = statezatpos2;
maxwell_smart3 = document.getElementById('oknochat');
maxwell_smart3.style.visibility = statezatcha2;
}
document.getElementById("priatinn").innerHTML='<iframe frameborder="0" src="jsphp/framepriatelia.php" style="width:300px; height:450px;"></iframe>';
}


function otvchat() {
stateotvcha = 'visible';
statezatpos3 = 'hidden';
statezatpri3 = 'hidden';

if (document.all) { //IS IE 4 or 5 (or 6)
eval( "document.all.oknopriatelia.style.visibility = statezatpri3");
eval( "document.all.oknoposta.style.visibility = statezatpos3");
eval( "document.all.oknochat.style.visibility = 'visible'");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers['oknopriatelia'].visibility = statezatpri3;
document.layers['oknoposta'].visibility = statezatpos3;
document.layers['oknochat'].visibility = 'visible';
}
if (document.getElementById && !document.all) {
maxwell_smart2 = document.getElementById('oknopriatelia');
maxwell_smart2.style.visibility = statezatpri3;
maxwell_smart = document.getElementById('oknoposta');
maxwell_smart.style.visibility = statezatpos3;
maxwell_smart3 = document.getElementById('oknochat');
maxwell_smart3.style.visibility = 'visible';
}
}

function vlozpre(pre) {
document.getElementById('novppre').value = pre;
}

function vynuluj() {
	document.getElementById("novptext").value='';
	document.getElementById("novpobr").value='';
}

function formz() {
	setTimeout("vynuluj()", 300);
}

function vynuluj2() {
	document.getElementById("odptext").value='';
	document.getElementById("odpobr").value='';
}

function formz2() {
	setTimeout("vynuluj2()", 300);
}



function formnchat() {
	novys = document.getElementById("novchskym").value;
	zobrazchat('novchat','z0',novys,'z0');
	setTimeout("vynuluj3()", 300);
}

function vynuluj3() {
	document.getElementById("novchskym").value='';
}

function vlozcpre(pre) {
document.getElementById("novchskym").value=pre;
}

function zobrazokienkascr() {
	setTimeout("zobrazokienka()", 1000);
	if (document.all) { //IS IE 4 or 5 (or 6)
	eval( "document.all.okienka.style.visibility = 'visible'");
	}
	if (document.layers) { //IS NETSCAPE 4 or below
	document.layers['okienka'].visibility = "visible";
	}
	if (document.getElementById && !document.all) {
		tr = document.getElementById('okienka');
		tr.style.visibility = "visible";
	}
}

function zobrazokno(c,skym) {
	window.open('http://www.lubim.sk/jsphp/chatx.php?c='+c+'&komu='+skym,skym+' - Chat RC','menubar=no,toolbar=no,location=no,scrollbars=no,width=600,height=420,left=200,top=150,screenX=200,screenY=150'); return false
}



	var chidje;
	var phidje;

var doctitorig = document.title;
var doctitnov = ' + '+document.title;
var doctitnov2 = ' ++ '+document.title;
setInterval("zmentitle()",6000);


function zmentitle() {
    phidje = document.getElementById('phid').value; 
	chidje = document.getElementById('chid').value; 
	if(phidje>"0" || chidje>"0")
	{
        document.title=doctitnov;
		setTimeout('title2()',3000);
	}
	else
	{
		document.title=doctitorig;
	}
}
function titlespat() {
	document.title=doctitorig;
}
function title2() {
	document.title=doctitnov2;
}





function DlzkaTextu(id,min,max) {
    if(document.getElementById(id)) {
        var text = document.getElementById(id).value;
        if(text.length <= min || text.length >= max) {
            document.getElementById(id).style.color='#BC0300';
        } else {
            document.getElementById(id).style.color='#000000';
        }
    }
}

function Cislo(id,min,max) {
    if(document.getElementById(id)) {
        
        var cislo = document.getElementById(id).value;
        cislo = Number(cislo);
        if(cislo < min || cislo > max) {
            document.getElementById(id).style.color='#BC0300';
        } else {
            document.getElementById(id).style.color='#000000';
        }
    }
}











//-->
