lck=0;
function change(champ,hval)
{
if(champ=="bordure")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).bgColor=hval; 
                 else document.all[id].bgColor=hval; 
                }
}
else if(champ=="font")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).bgColor=hval; 
                 else document.all[id].bgColor=hval;
	}
}
else if(champ=="titre")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(champ=="texte")
{
	if ( lck == 0 )
                {document.f.jv_texte.value=hval;
	         if(document.getElementById) document.getElementById(champ).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(champ=="lien")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(champ=="lien2")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(champ=="lien3")
{
	if ( lck == 0 )
                {if(document.getElementById) document.getElementById(champ).color=hval; 
                 else document.all[id].color=hval;
                }
}
}

function r(hval)
{
aaa = document.f.choix.selectedIndex;
a = document.f.choix.options[aaa].value;
if(a=="bordure")
{
	if ( lck == 0 )
                {document.f.jv_bordure.value=hval;
                 if(document.getElementById) document.getElementById(a).bgColor=hval; 
                 else document.all[id].bgColor=hval; 
                }
}
else if(a=="font")
{
	if ( lck == 0 )
                {document.f.jv_font.value=hval;
	         if(document.getElementById) document.getElementById(a).bgColor=hval; 
                 else document.all[id].bgColor=hval;
	}
}
else if(a=="titre")
{
	if ( lck == 0 )
                {document.f.jv_titre.value=hval;
	         if(document.getElementById) document.getElementById(a).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(a=="texte")
{
	if ( lck == 0 )
                {document.f.jv_texte.value=hval;
	         if(document.getElementById) document.getElementById(a).color=hval; 
                 else document.all[id].color=hval;
                }
}
else if(a=="lien")
{
	if ( lck == 0 )
                {document.f.jv_lien.value=hval;
	         if(document.getElementById) document.getElementById(a).color=hval;
                 else document.all[id].color=hval;
                }
}
}

function l()
{
	if (lck == 0)
	lck = 1;
	else
	lck = 0;
}

function raz()
	{
	RAZVar()
	document.f.reset();
	document.ScriptForm.reset();
        }

function appercu()
        {
        jv_format = document.f.format.value;
	jv_bordure = document.f.jv_bordure.value;
	jv_font = document.f.jv_font.value;
	jv_titre = document.f.jv_titre.value;
	jv_texte = document.f.jv_texte.value;
	jv_lien = document.f.jv_lien.value;
	
        window.open('sortie_appercu.php?jv_format='+ jv_format +'&jv_bordure='+jv_bordure+'&jv_font='+jv_font+'&jv_titre='+jv_titre+'&jv_texte='+jv_texte+'&jv_lien='+jv_lien+'','popup','toolbar=0,location=0,directories=0,menuBar=0,resizable=1,scrollbars=1,width=550,height=400,top=50,left=50');
        }
	
function editCode()
	{
	jv_format = document.f.format.value;
	jv_bordure = document.f.jv_bordure.value;
	jv_font = document.f.jv_font.value;
	jv_titre = document.f.jv_titre.value;
	jv_texte = document.f.jv_texte.value;
	jv_lien = document.f.jv_lien.value;
	
        headtxt  = '<script type=\"text/javascript\">\n';
        headtxt += 'jv_bordure = "'+jv_bordure+'"\n';
        headtxt += 'jv_font ="'+jv_font+'"\n';
        headtxt += 'jv_titre ="'+jv_titre+'"\n';
        headtxt += 'jv_texte ="'+jv_texte+'"\n';
        headtxt += 'jv_lien ="'+jv_lien+'"\n';
        headtxt += '</script>\n';
        headtxt += '<script type=\"text/javascript\" src=\"http://www.todoocinema.com/sortie_'+jv_format+'.js\"></script>\n';
        headtxt += '<noscript><a href=http://www.todoocinema.com>Todoo Cinema</a></noscript>\n';
        
	document.ScriptForm.body.value = headtxt;
	}

function mpChangePropertie(oref,val) {
document.getElementById(oref).bgcolor=val;
}

function mpChangeInputPropertie(oref,prop,val) { for(var i=0; i<10; i++) { o = document.getElementById(oref); if (o) { o.style[prop] = val; } } }

