Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- checkLang();
- function checkLang(){
- if (jQuery('.LanguageSelector').val() == 'en-US'){
- hideFrench();
- }else if (jQuery('.LanguageSelector').val() == 'fr-FR'){
- hideEnglish();
- }
- }
- function hideEnglish(){
- jQuery('.iMIS-WebPart').each(function(index,key) {
- var id = jQuery(key).children('div').attr('id');
- var isEnglish = id.match(/LANGEN/g);
- if (id && isEnglish){
- jQuery(key).children('#' + id).css('display','none');
- return false;
- }
- });
- }
- function hideFrench(){
- jQuery('.iMIS-WebPart').each(function(index,key) {
- var id = jQuery(key).children('div').attr('id');
- var isFrench = id.match(/LANGFR/g);
- if (id && isFrench){
- jQuery(key).children('#' + id).css('display','none');
- return false;
- }
- });
- }
- removeLanguages();
- function removeLanguages(){
- jQuery(".LanguageSelector option[value='es-ES']").remove();
- jQuery(".LanguageSelector option[value='nl-NL']").remove();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement