var ddopen = false;


function getEl(id){
    if(document.layers){
        return document.layers[id];
    }
    if(document.all && document.all.item){
        return document.all[id];
    }
    if(document.getElementById){
        return document.getElementById(id);
    }
}

function rover(ob){
	a=ob.src.split("_n").join("_h");
	ob.src=a;
}
function rout(ob){
	a=ob.src.split("_h").join("_n");
	ob.src=a;
}

function he(){
    if(document.body.clientWidth){
	   wdt = document.body.clientWidth;
	   clh = document.body.clientHeight;
    }
    if(window.innerWidth){
	   wdt = window.innerWidth;
	   clh = window.innerHeight;
    }
    return clh;
}

function ddmenu(btn){
    //alert(ddopen);
    ob = getEl('addcomment');
    if(!ddopen){
        ob.style.display = 'block';
        /*a=btn.src.split("closed").join("open");
	    btn.src=a;*/
	    ddopen = true;
    } else {
        ob.style.display = 'none';
        /*a=btn.src.split("open").join("closed");
	    btn.src=a;*/
	    ddopen=false;
    }
}


function init(){
    //alert("");
    var ob = getEl('vertr');
    ob.height = he()-319;
    document.images['cn'].src = 'cntr-js.php?f='+detectFlash()+'&w='+screen.width+'&h='+screen.height;
}


