
function SwitchLang(FolderName,isParent){
  var Slash;

  location.href.indexOf('/')>0?Slash='/':Slash='\\';

  sloc=location.href.replace(Slash+FolderName,'');
  if (isParent)
	location.href =sloc;
  else {

  	firstpos=sloc.lastIndexOf(Slash)+1;
  	newloc=sloc.substring(0,firstpos)+ FolderName+ sloc.substring(firstpos-1);
  	//alert(newloc);
  	location.href=newloc;


}




}


