//   ************************************************************************//
//   * Module Name		: InitCJeunes.js									*//
//   * Release			: 3.0												*//
//   * Date				: 01/01/2009										*//
//   * Project			: AGSE_TT											*//
//   * Author			: aCOSwt											*//
//   * Description		: Scripts associated with CFrance.html management.	*//
//   * History			: 1.0 : First Site Version							*//
//	 *					  2.0 : Table entirely JS built						*//
//	 *					  3.0 : Accomodation to CJeunes PHPisation			*//
//   * Language			: JavaScript										*//
//   * Compatibility	: FireFox 2 - IE 7 - Opera 9 - Konqueror 3			*//
//   ************************************************************************//

//********************************** Global variables ***********************//

	var	Linestate;

//******************************* Main Init Procedure entry point ***********//

function initCJeunes(){

	var	user_id;

	Linestate=new Array();
	for(i=0;i<30;Linestate[i++]=0);
	user_id=initPage(1,0,8);
	disp_mespers(user_id);}

//************************* Display Personal Message if appropriate *********//

function disp_mespers(user_id){

	var mespers;

	if(user_id)
		if(typeof(_TC[user_id])!="undefined"){
			mespers="Tu es sélectionné avec "+_TC[user_id];
			document.getElementById("PERSMES").innerHTML=mespers;
			document.getElementById("FIREBALL").style.display="block";}}

//**************************** Display team details *************************//

function DisplayDetails(lineid){

	element=document.getElementById("IFDET_"+lineid);
	if(!Linestate[parseInt(lineid)]){
		element.style.height="325px";
		Linestate[parseInt(lineid)]=1;}
	else{
		element.style.height="0px";
		Linestate[parseInt(lineid)]=0;}}

//************************** Show associated Photo **************************//

function DisplayPhoto(lineid,photo_file){

	HighlightTabLine("GNRLTR"+lineid);
	if(photo_file!="")
		DisplayWide(136,"http://www.essarts-le-roi-tt.fr/Photos/CJeunes/"+photo_file+".jpg");}

//************************ Hide associated Photo ****************************//

function HidePhoto(lineid){

	UnlightTabLine("GNRLTR"+lineid);
	HideLayer("PHOTODIV");}