function verifForm() {
	var tPost = new Array('nom','telephone','email','sujet','message');
	for(var i = 0;i<tPost.length;i++) {
		if(eval("document.fContact."+tPost[i]+".value")== "") {
			alert('Vous devez renseigner le champ ' + tPost[i]);
			return false;
		}
	}
	return true;
}
function xGetElementsByClassName(c,p,t,f)
{
  var r = new Array();
  var re = new RegExp("(^|\\s)"+c+"(\\s|$)");
//  var e = p.getElementsByTagName(t);
  var e = xGetElementsByTagName(t,p); // See xml comments.
  for (var i = 0; i < e.length; ++i) {
    if (re.test(e[i].className)) {
      r[r.length] = e[i];
      if (f) f(e[i]);
    }
  }
  return r;
}
// xGetElementsByTagName r5, Copyright 2002-2007 Michael Foster (Cross-Browser.com)
// Part of X, a Cross-Browser Javascript Library, Distributed under the terms of the GNU LGPL

function xGetElementsByTagName(t,p)
{
  var list = null;
  t = t || '*';
  p = xGetElementById(p) || document;
  if (typeof p.getElementsByTagName != 'undefined') { // DOM1
    list = p.getElementsByTagName(t);
    if (t=='*' && (!list || !list.length)) list = p.all; // IE5 '*' bug
  }
  else { // IE4 object model
    if (t=='*') list = p.all;
    else if (p.all && p.all.tags) list = p.all.tags(t);
  }
  return list || [];
}
function xGetElementById(e)
{
  if(typeof(e)=='string') {
    if(document.getElementById) e=document.getElementById(e);
    else if(document.all) e=document.all[e];
    else e=null;
  }
  return e;
}
function xNextSib(e,t)
{
  e = xGetElementById(e);
  var s = e ? e.nextSibling : null;
  while (s) {
    if (s.nodeType == 1 && (!t || s.nodeName.toLowerCase() == t.toLowerCase())){break;}
    s = s.nextSibling;
  }
  return s;
}
function xFirstChild(e,t)
{
  e = xGetElementById(e);
  var c = e ? e.firstChild : null;
  while (c) {
    if (c.nodeType == 1 && (!t || c.nodeName.toLowerCase() == t.toLowerCase())){break;}
    c = c.nextSibling;
  }
  return c;
}

function init() {
	initPopUp('divPopUp');
	initPopUp('divPopUp2');
}
function initPopUp(class_) {
	var e = xGetElementsByClassName(class_,'','div');
	var elA;
	for(var i=0;i<e.length;i++) {
		e[i].onmouseover = function() {
			var ela = xFirstChild(this);
			var el =xNextSib(ela);
			el.style.visibility = 'visible';
		}
		e[i].onmouseout = function() {
			var ela = xFirstChild(this);
			var el =xNextSib(ela);
			el.style.visibility = 'hidden';
		}
	}
	
}

