// JavaScript Document
function reagir(ici) {
	document.getElementById('form_reaction' + ici).innerHTML = "<textarea name='message' wrap='virtual' style='width:460px; height:50px; border-style:solid; border-width:1px; background-color:#ebebeb'>Votre réaction</textarea><br /><input type='submit' value='Valider' /></form>";
}

function ajouter_favoris() {
	if(navigator.appName != 'Microsoft Internet Explorer')
		window.sidebar.addPanel("Handicap Infos", "http://www.handicapinfos.com", "");
	else
		window.external.AddFavorite("http://www.handicapinfos.com", "Handicap Infos");
}

function imprimer_page() {
	window.print();
}

function redim_textes(taille) {
	window.location = "http://www.handicapinfos.com/cookie_confort.php?url=" + window.location + "&taille_confort=" + taille;
}

var x = 0;
var y = 0;
function activer_glossaire(terme, definition, e) {
	if (document.all) {
		x = event.clientX + document.documentElement.scrollLeft;
		y = event.clientY + document.documentElement.scrollTop;
 	}
 	else {
 		x = e.pageX;
 		y = e.pageY;
 	}

	document.getElementById("calque_glossaire").innerHTML = "<span style='font-weight:bold; color:#036'>" + terme + "</span>&nbsp;: " + definition;
	document.getElementById("calque_glossaire").style.left = x - 240 + "px";
	document.getElementById("calque_glossaire").style.top = y - 12 + "px";
	document.getElementById("calque_glossaire").style.visibility = 'visible';
}

function masquer_glossaire() {
	document.getElementById("calque_glossaire").style.visibility = 'hidden';
}

var ouvert = new Array();
for($a=0; $a<1000; $a++) {
	ouvert[$a] = 0;	
}
var statut = new Array('none', 'block');
var fleche = new Array('closed', 'opened');
var filet = new Array('bbbbbb', 'cc0000');
function ouvrir_dossier(no) {
	ouvert[no] = Math.abs(ouvert[no] - 1);
	eval("document.getElementById('forum" + no + "')").style.display = statut[ouvert[no]];
	eval("document.getElementById('fleche" + no + "')").src = '../images/arrow_' + fleche[ouvert[no]] + '.gif';
	// eval("document.getElementById('filet" + no + "')").src = '../images/z_' + filet[ouvert[no]] + '.gif';
}
