//scroll----------------------------------------------------------------

function toTop(id){
document.getElementById(id).scrollTop=0
}

defaultStep=1
step=defaultStep
function scrollDivDown(id){
document.getElementById(id).scrollTop+=step
timerDown=setTimeout("scrollDivDown('"+id+"')",10)
}

function scrollDivUp(id){
document.getElementById(id).scrollTop-=step
timerUp=setTimeout("scrollDivUp('"+id+"')",10)
}

function toBottom(id){
document.getElementById(id).scrollTop=document.getElementById(id).scrollHeight
}




// les popups--------------------------------------------------------------

function popup(ici,popupname,height,width) 
{
	var topPosition = 0;
	var leftPosition = (screen.width - width) / 2;
	var windowprops = "width=" + width + ",top=" + topPosition + ",left=" + leftPosition + ",location=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,status=no";

	window.open(ici.href,popupname,windowprops);
	return false
}

function blank(ici,popupname){window.open(ici.href,popupname,'location=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,status=no'); return false }
 


// popup images formulaire--------------------------------------------------

function AfficherImage(img){
  Image1= new Image();
  Image1.src=(img);
  Control(img);
}
function Control(img){
  if((Image1.width!=0)&&(Image1.height!=0)){
    VoirImage(img);
  }
  else{
    fonction="Control('"+img+"')";
    intervalle=setTimeout(fonction,20);
  }
}
function VoirImage(img){
  largeur=Image1.width+20;
  hauteur=Image1.height+20;
  proprietes="width="+ largeur +",height="+ hauteur;
  win=window.open(img,"",proprietes);
}



// sommaire de la fiche------------------------------------------------------
function showsummary()
{ 
  if (navigator.appName=='Microsoft Internet Explorer')
  { document.all.txt_summary.style.visibility='visible' }
  else
  { document.getElementById('txt_summary').style.visibility='visible' }
;}

function hidesummary() 
{
  if (navigator.appName=='Microsoft Internet Explorer')
  { document.all.txt_summary.style.visibility='hidden' }
  else
  { document.getElementById('txt_summary').style.visibility='hidden' }
;}
