I have inherited a website that is both English and French. On the header of every page is some text that says "View this page in: <language>". The default right now is French. I want the default to always be English.

Here is the script to set the cookie:

$(document).ready(function(){
var currentlanguage = Get_Cookie('Language');
if(currentlanguage==''){
Set_Cookie('Language','English','', '/', '', '' );
currentlanguage=Get_Cookie('Language');
}

else if(currentlanguage=='English'){
$('.frenchContent').hide();
$('.englishContent').show();
$('#changeLanguage').text('Franšais');
$('#selectTopic').html('');
$('#selectTopic').html($('.genQuestion').html());
$('#selectCategory').html('');
$('#selectCategory').html($('.byCategory').html());
}
else{
$('.englishContent').hide();
$('.frenchContent').show();
$('#changeLanguage').text('English');
$('#selectTopic').html('');
$('#selectTopic').html($('.genQuestionfr').html());
$('#selectCategory').html('');
//alert($('#selectCategory').html());
//alert($('.byCategoryfr').html())
$('#selectCategory').html($('.byCategoryfr').html());
}

});


THEN....there is this HTML on the header of every page:

<div style="float:right;">See this page in: <a href="#" id="changeLanguage">Fran&ccedil;ais</a></div>
ats is online now Add to ats's Reputation Report Post Reply With Quote