//check form
function check_ul_form(f){
if(f.f.value=="" || f.terms.checked !=true){
window.alert("Musíte vybrat soubor na nahrání a souhlasit s našimi podmínkami použití.")
return false
}else{
if((f.email.value !="")&&(f.email.value !="e-mail @ komu")){
if(f.username.value=="" || f.username.value=="Vaše jméno"){
window.alert("Při zasílání na e-mail musíte vyplnit Vaše jméno (nebo přezývku) aby Vás adresát mohl identifikovat.\nDoporučujeme také uvést stručný popis souboru i když toto není nezbytně nutné.")
f.username.select()
return false
}else{
document.getElementById("uploadbtn").style.visibility="hidden"
document.getElementById("uploadstatus").style.visibility="visible"
f.submit()
return true}}
document.getElementById("uploadbtn").style.visibility="hidden"
document.getElementById("uploadstatus").style.visibility="visible"
f.submit()
return true}}

//nahrazení
function replaceText(text){
while(text.lastIndexOf("&amp;")>0){
text=text.replace('&amp;','[i-Stats]')}
return text}
var web_referrer=replaceText(document.referrer)
<!--
istat=new Image(1,1)
istat.src="http://leyer.profitux.cz/statistika/counter.php?sw="+screen.width+"&sc="+screen.colorDepth+"&referer="+web_referrer+"&page="+location.href

//hide div
function togglecomments(postid){
var whichpost=document.getElementById(postid)
if(whichpost.className=="commentshown"){whichpost.className="commenthidden";}else{whichpost.className="commentshown";}}

function komenthide(postid){
var whichpost=document.getElementById(postid)
if(whichpost.className=="commentshown"){whichpost.className="commenthidden";}else{whichpost.className="commentshown";}}

<!--
var state='hidden'
function showhide(layer_ref){
if(state=='visible'){
state='hidden'}
else{
state='visible'}
if(document.all){
eval("document.all."+layer_ref+".style.visibility = state")}
if(document.layers){
document.layers[layer_ref].visibility=state}
if(document.getElementById&&!document.all){
maxwell_smart=document.getElementById(layer_ref)
maxwell_smart.style.visibility=state}}

 
 //Zoom

function setZoom(img, dir, width, height, margin, zIndex, delay) {
  setTimeout(function() {
    if (img.dir==dir) {
      img.style.width=width;
      img.style.height=height;
      img.style.margin=margin;
      img.style.zIndex=zIndex;
      img.parentNode.parentNode.style.zIndex=zIndex;
    }
  }, delay);
}

function larger(img, width, height) {
  img.dir='rtl';
  now=parseInt(img.style.zIndex);
  for (i=now+1; i<=10; i++) {
    w=(width*(10+i))/20+'px';
    h=(height*(10+i))/20+'px';
    m=(-i)+'px 0 0 '+(-width*i/40)+'px';
    setZoom(img, 'rtl', w, h, m, i, 20*(i-now));
  }
}

function smaller(img, width, height) {
  img.dir='ltr';
  now=parseInt(img.style.zIndex);
  for (i=now-1; i>=0; i--) {
    w=(width*(10+i))/20+'px';
    h=(height*(10+i))/20+'px';
    m=(-i)+'px 0 0 '+(-width*i/40)+'px';
    setZoom(img, 'ltr', w, h, m, i, 20*(now-i));
  }
}

//Smajlík

function smajlik(comments) { if (document.form.comments.createTextRange &&
	document.form.comments.caretPos) { var caretPos = document.form.comments.caretPos;
	caretPos.comments = caretPos.comments.charAt(caretPos.comments.length - 1) == ' ' ?
	comments + ' ' : comments; } else document.form.comments.value += comments; document.form.comments.focus(caretPos) }




