var J = jQuery.noConflict(); 
var $j = jQuery.noConflict();
$j(function(){
		  $j('.nav-one').hide(); 
	$j('#menu1 ul li.dd, #menu2 ul li.dd2').mouseover(function(){
			$j(this).children('.nav-one').show();
			$j(this).children('a.lien, a.lien2').addClass('hover');
		});
});
$j(function(){
	$j('#menu1 ul li.dd, #menu2 ul li.dd2').mouseleave(function(){
			$j(this).children('.nav-one').hide();
			$j(this).children('a.lien, a.lien2').removeClass('hover');
		});
});

window.addEvent('domready', function() {
    new FormCheck('form1');  
	var initMultiBox = new multiBox({
		mbClass: '.mb',//class you need to add links that you want to trigger multiBox with (remember and update CSS files)
		container: $(document.body),//where to inject multiBox
		descClassName: 'multiBoxDesc',//the class name of the description divs
		useOverlay: true,//use a semi-transparent background. default: false;
		//maxSize: {w:800, h:300},//max dimensions (width,height) - set to null to disable resizing
		addDownload: false,//do you want the files to be downloadable?
		//pathToDownloadScript: './Scripts/ForceDownload.asp',//if above is true, specify path to download script (classicASP and ASP.NET versions included)
		addRollover: false,//add rollover fade to each multibox link
		addOverlayIcon: false,//adds overlay icons to images within multibox links
		addChain: false,//cycle through all images fading them out then in
		recalcTop: true,//subtract the height of controls panel from top position
		addTips: false,//adds MooTools built in 'Tips' class to each element (see: http://mootools.net/docs/Plugins/Tips)
		showControls: false,//show the previous/next, title, download etc
		contentColor: '#000'//background colour of the content holder within the pop-up

	});

	
});


function lookup(inputString,actionmethod,url) {
	
	if(inputString.length == 0) {
		// Hide the suggestion box.
		$j('#suggestions').hide();
	} else {
		
		$j.post(url, {queryString: ""+inputString+"",actionmethod: ""+actionmethod+""}, function(data){
			if(data.length >0) {
				$j('#suggestions').show();
				$j('#autoSuggestionsList').html(data);
			}
		});
	}
} // lookup

function fill(thisValue) {
	
	$j('#inputString').val(thisValue);
	setTimeout("$j('#suggestions').hide();", 200);
}

function date_fr(el)
{
	if (!el.value.test(/^([0-3][0-9])(\/)([0-1][0-9])(\/)([0-9]{4})/))
	{
		el.errors.push("Veuillez saisir une date de naissance valide au format suivant:<br /><span>Ex. 01/01/1970</span>");
		return false;
	}
	else
	{
		return true;
	}
}
