function changeWindows() {
	window.location.href = getFileName(window.location.href);
}

function getFileName(frameFile) {
	var lastSlash = frameFile.lastIndexOf("/");
	var fullPath = frameFile.substring(0, lastSlash+1);
	var fileName = unescape(frameFile.substring(lastSlash+1));
	var fileUS = fileName.lastIndexOf("_");
	var cLang = fileName.charAt(fileUS+1);

	fileName = cLang == 'e'
		? substLast(fileName, '_e.', '_f.')
		: substLast(fileName, '_f.', '_e.');
	fileName = fullPath + fileName;
	return relocateUrl == ''
		? fileName
		: relocateUrl;
}

function substLast(aString, c1, c2) {
	if (aString == "") return aString;

	var i = aString.lastIndexOf(c1);
	if (i < 0) return aString;

	var s1 = aString.substring(0, i);
	var s2 = aString.substring(i+c1.length, aString.length);
	return s1+c2+s2;
}
		
function redmenuOver(tdID, tdClass) {
	var prop = document.getElementById(tdID);
	prop.className = prop.className == 'redmenuMainLevel'
		? 'redmenuMainSelect'
		: 'redmenuSubSelect';
	return false;
}

function redmenuOut(tdID, tdClass) {
	prop = document.getElementById(tdID);
	prop.className = prop.className == 'redmenuMainSelect'
		? 'redmenuMainLevel'
		: 'redmenuSubLevel';
	return false;
}

function setMenuBackground() {
	if ( document.all && !window.opera ) {
		var num = [ '01', '02', '03', '04', '05',  '06',  '07',  '08',  '09',  '10',  '11',  '12',  '13',  '14',  '15',  '16',  '17',  '18',  '19',  '20',  '21',  '22',  '23',  '24',  '25' ];
		var pos = window.location.href.match(/_e\./)
			? [ '0', '23', '46', '69', '85', '100', '115', '137', '175', '198', '221', '237', '280', '295', '310', '325', '347', '377', '392', '407', '429', '459', '502', '517', '539' ]
			: [ '0', '23', '46', '69', '85', '100', '115', '137', '175', '213', '236', '252', '281', '296', '311', '326', '348', '378', '393', '408', '430', '460', '517', '532', '554' ];
		for ( var i = 0; i < num.length; i++ ) {
			document.getElementById('mn' + num[i])
				? document.getElementById('mn' + num[i]).style.backgroundPosition = '0px -' + pos[i] + 'px'
				: null;
		}
	}
}

<!--

function lang(l) {
	var search = '_' + l + '.';
	if (l == 'e') { ol = 'f' } else { ol = 'e' }
	if (parent.location.href.indexOf(search) >-1) {
		parent.location.href = parent.location.href.substring(0,(parent.location.href.lastIndexOf(search)+1)) + ol + parent.location.href.substring(parent.location.href.lastIndexOf(search)+2,parent.location.href.length);
	} 
}

function printIt() {

if (window.print) {
   window.print();
}

else {
alert('Press "CTRL-P" to print this page');
}

}

function printVersionColdFusion() {


FileURL = parent.location.href + '&template=print';
window.open(FileURL, 'Print', 'width=615,height=400,top=10,left=100,toolbar=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,');
}

function preview(FileURL) {
  	window.open(FileURL, 'Preview', 'width=450,height=419,top=10,left=10,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,');
}

function revise(FileURL) {
  	window.open(FileURL, 'Revise', 'width=575,height=332,top=10,left=10,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,');
}


if (document.images) {
	img1on = new Image();           // Active images
	img1on.src = "/bookstore/images/myaccount_over.gif";  
	img2on = new Image();
	img2on.src = "/bookstore/images/viewyourcart_over.gif";  
	img3on = new Image();
	img3on.src = "/bookstore/images/continueshopping_over.gif";  
	img4on = new Image();
	img4on.src = "/bookstore/images/proceedtocheckout_over.gif";  
	img5on = new Image();
	img5on.src = "/bookstore/images/search-e_over.gif";  
	img6on = new Image();
	img6on.src = "/bookstore/images/instructionshelp_over.gif";  
	img1off = new Image();          // Inactive images
	img1off.src = "/bookstore/images/myaccount.gif"; 
	img2off = new Image();
	img2off.src = "/bookstore/images/viewyourcart.gif"; 
	img3off = new Image();
	img3off.src = "//bookstore/images/continueshopping.gif"; 
	img4off = new Image();
	img4off.src = "/bookstore/images/proceedtocheckout.gif"; 
	img5off = new Image();
	img5off.src = "/bookstore/images/search-e.gif";  
	img6off = new Image();
	img6off.src = "/bookstore/images/instructionshelp.gif";  
  }
  
  
    function imgOn(imgName) {
            if (document.images) {
                document[imgName].src = eval(imgName + "on.src");
            }
    }
    function imgOff(imgName) {
            if (document.images) {
                document[imgName].src = eval(imgName + "off.src");        
            }
    }
//-->