function toggle(id) {
    var e = document.getElementById(id);
    if(e.style.display == 'block')
	e.style.display = 'none';
    else
	e.style.display = 'block';
} 


    function show(id1, id2, id3, id4, id5, id6) {
    var e1 = document.getElementById(id1);
    if (e1)
    e1.style.display = 'block';
    var e2 = document.getElementById(id2);
    if (e2)
    e2.style.display = 'block';
    var e3 = document.getElementById(id3);
    if (e3)
    e3.style.display = 'block';
    var e4 = document.getElementById(id4);
    if (e4)
    e4.style.display = 'block';
    var e5 = document.getElementById(id5);
    if (e5)
    e5.style.display = 'block';
    var e6 = document.getElementById(id6);
    if (e6)
    e6.style.display = 'block';
    }

    function hide(id1, id2, id3, id4, id5, id6) {
    var e1 = document.getElementById(id1);
    if (e1)
    e1.style.display = 'none';
    var e2 = document.getElementById(id2);
    if (e2)
    e2.style.display = 'none';
    var e3 = document.getElementById(id3);
    if (e3)
    e3.style.display = 'none';
    var e4 = document.getElementById(id4);
    if (e4)
    e4.style.display = 'none';
    var e5 = document.getElementById(id5);
    if (e5)
    e5.style.display = 'none';
    var e6 = document.getElementById(id6);
    if (e6)
    e6.style.display = 'none';
    } 

    function hidex(id1) {
	var iframe = document.getElementById('dd');
	iframe.parentNode.removeChild(iframe);
    }

function hide_block() {
    var block = document.getElementById('play_block');
    if (block) {
    hide('play_block');
    } 
}


var timy = 12;
var intervalid = 0;

function startcount() {	   
    timy = eval(timy - 1);   
    if (timy == 0) {
	clearInterval(intervalid);
	hide_block();
    }
}

function countdown() {
    intervalid = setInterval("startcount()", 1000);   
}


function popup(url) {
    ok = window.open(url, "share", "status=0,toolbar=0,location=0,menubar=0,directories=0,scrollbars=0,height=600,width=800")
    if (ok) {
	countdown();
	return false;
    }
    else return true;
} 







/*
var timy = 10;
var countstand = getElementById('countstand');
var intervalid = 0;

function startcount() {	   
    timy = eval(timy - 1);
    countstand.innerHTML = timy;
    
    if (timy == 0) {
	hide('countdown');
	clearInterval(intervalid);
	hide_block();
    }
}



function countdown() {
    countstand = document.getElementById('countstand');

    intervalid = setInterval("startcount()", 1000);   
}

*/

