/*<!-- mp_trans_disable_start -->*/ 
var SelectCountryLanuage={constructor:function()
{Event.observe(window,'load',this.windowOnLoad.bindAsEventListener(this));},windowOnLoad:function(event)
{if($('langSelection'))
$('langSelection').show();if($('countryCode'))
{Event.observe($('countryCode'),'change',this.loadLanguageOptions.bindAsEventListener(this));if($('countryCode').selectedIndex>0)
this.loadLanguageOptions();}
if($('selectCountryLanguage'))
Event.observe($('selectCountryLanguage'),'submit',this.onFormSubmit.bindAsEventListener(this))},onFormSubmit:function(event)
{var msg='';if(Form.Element.getValue('countryCode')=='')
{msg+='Veuillez s\351lectionner un pays.\n';}
if(Form.Element.getValue('languageCode')=='')
{msg+='Veuillez s\351lectionner une langue.\n';}
if(msg!='')
{alert(msg);Event.stop(event);return false;}},loadLanguageOptions:function(event)
{if(Form.Element.getValue('countryCode')!='')
{new Ajax.Updater($('languageCodeContainer'),$('selectCountryLanguage').action+'?'+Form.serialize($('selectCountryLanguage')),{onSuccess:this.checkForError.bind(this)});}
else
{alert('Veuillez s\351lectionner un pays.');}},checkForError:function(request)
{if(!request.responseText.match(/<option/gi))
alert('erreur dans la recherche de langues');$('loadingMsg').hide();}};SelectCountryLanuage=Base.extend(SelectCountryLanuage);
 /*<!-- mp_trans_disable_end -->*/