/* File: js/ajaxfonctions.js, Ratio: 12.7% */
<!--
var ajax;function openCloseDiv()
{if($('ultraContentDyn').visible())
{var ajax=new Ajax.Updater('ultraContentDyn',emptyurl,{asynchronous:true,evalScripts:true,onComplete:closeDiv});}
else
{new Effect.toggle('ultraContentDyn','blind',{duration:0.2,asynchronous:true,afterFinish:changeContenu});changeBarre();}}
function changeBarre()
{if($('ultraCaseContainer').visible())
{new Effect.Fade('ultraCaseContainer',{duration:0.6,asynchronous:true});$('ultraBoutonInner').src='/img/habillage/ultrabouton_up.gif';}
else
{new Effect.Appear('ultraCaseContainer',{duration:0.6,asynchronous:true});$('ultraBoutonInner').src='/img/habillage/ultrabouton_down.gif';}}
function changeContenu()
{var ajax=new Ajax.Updater('ultraContentDyn',url,{asynchronous:true,evalScripts:true});}
function closeDiv()
{new Effect.toggle('ultraContentDyn','blind',{duration:0.2,asynchronous:true});changeBarre();}
function trailerIconOpen()
{if($('trailerList').visible())
{new Effect.toggle('trailerList','blind',{duration:0.4,afterFinish:showIcon});$('bootIcon').src='/img/habillage/barElements_bootIconOn.gif';$('bootList').src='/img/habillage/barElements_bootListOff.gif';}}
function trailerListOpen()
{if($('trailerIcon').visible())
{new Effect.toggle('trailerIcon','blind',{duration:0.4,afterFinish:showList});$('bootIcon').src='/img/habillage/barElements_bootIconOff.gif';$('bootList').src='/img/habillage/barElements_bootListOn.gif';}}
function showIcon()
{new Effect.toggle('trailerIcon','blind',{duration:0.4});}
function showList()
{new Effect.toggle('trailerList','blind',{duration:0.4});}
function genreListOpen()
{if($('alphaList').visible())
{new Effect.toggle('alphaList','blind',{duration:0.2,afterFinish:showGenre});}
else
{showGenre();}}
function alphaListOpen()
{if($('genreList').visible())
{new Effect.toggle('genreList','blind',{duration:0.2,afterFinish:showAlpha});}
else
{showAlpha();}}
function showGenre()
{new Effect.toggle('genreList','blind',{duration:0.2});}
function showAlpha()
{new Effect.toggle('alphaList','blind',{duration:0.2});}
function getCookieVal(offset)
{var endstr=document.cookie.indexOf(";",offset);if(endstr==-1)endstr=document.cookie.length;return unescape(document.cookie.substring(offset,endstr));}
function LireCookie(nom)
{var arg=nom+"=";var alen=arg.length;var clen=document.cookie.length;var i=0;while(i<clen)
{var j=i+alen;if(document.cookie.substring(i,j)==arg)return getCookieVal(j);i=document.cookie.indexOf(" ",i)+1;if(i==0)break;}
return null;}
function DataCheck(f)
{var input=new Array;input[0]=f.elements["CompetitionEmail"];input[1]=f.elements["CompetitionNom"];input[2]=f.elements["CompetitionPrenom"];input[3]=f.elements["CompetitionAdresse"];input[4]=f.elements["CompetitionCodepostal"];input[5]=f.elements["CompetitionVille"];for(var i in input)
{if(input[i].value=='')
{input[i].className='bipbip';var erreur=true;}}
if(erreur)
{alert('Veuillez remplir tous les champs obligatoires.');return false;}
else if(!f.elements["CompetitionCgv"].checked)
{alert('Veuillez accepter les conditions d\'utilisation.');return false;}
else
{return true;}}
function urlSearch(f)
{if(f.elements["q"].value=='Votre recherche'||f.elements["q"].value=='')
{return false;}
window.location.href="http://www.fantasy.fr/searches/index/"+escape(f.elements["q"].value);return false;}
function FocusText(BoxName)
{if(BoxName.value==BoxName.defaultValue){BoxName.value='';}}
function BlurText(BoxName)
{if(BoxName.value=='')
{BoxName.value=BoxName.defaultValue;}}
