//*********************************************
// Tree Menu Copyright Simon Rycroft
// For more scripts go to:
// http://www.d-zineworx.co.uk
//*********************************************

// opens menu section - do not alter
function openMenu(cat) {
this.cat = cat;
document.write('<span class = "level1">');

if (cat == 'Investment Management'){
   document.write('<a href = "http://www.morganstanley.com/msim" target="_top" class="sidehead">');
}
else if (cat == 'US Liquidity'){
document.write('<a href = "' + relativeprefix + 'msil/index.html" target="_top" class="sidehead">');
}
else if (cat == 'Products'){
document.write('<a href = "' + relativeprefix + 'products/index.html?page=prod" target="_top" class="sidehead">');
}
else if (cat == 'Publications'){
document.write('<a href =  "' + relativeprefix + 'publications/index.html?page=publications" target="_top" class="sidehead">');
}
else if (cat == 'About Morgan Stanley &nbsp;&nbsp;Investment&nbsp;Management'){
document.write('<a href =  "' + relativeprefix + 'about/index.html?page=about" target="_top" class="sidehead">');
}
else if (cat == 'Client Resources'){
document.write('<a href =  "' + relativeprefix + 'resources/index.html?page=resources" target="_top" class="sidehead">');
}
else if (cat == 'Glossary'){
document.write('<a href =  "' + relativeprefix + 'glossary/index.html?page=glossary" target="_top" class="sidehead">');
}
else if (cat == 'Contact Us'){
document.write('<a href =  "' + relativeprefix + 'contact/index.html?page=contactus" target="_top" class="sidehead">');
}
else if (cat == 'Legal'){
document.write('<a href =  "' + relativeprefix + 'legal/index.html?page=legal" target="_top" class="sidehead">');
}

else {
document.write('<a href = "' + thisPage + '?page=null" target="_top" class="sidehead">');
}

if (lev1img=='yes') {
document.write('<img src="' + imgPath + lev1OpName +'" width="' + lev1OpWidth + '" height="' + lev1OpHeight + '"border="0">');
}
document.write(cat + '</a><span><br>');
for (x=0;x<thisMenu.length;x++){
 document.write('<span class = "level2">');
 if (lev2img=='yes') {
 document.write('<img src="' + imgPath + lev2Name +'" width="' + lev2Width + '" height="' + lev2Height + '">');
 }
 if (lev2Char=='yes') {
 document.write(bullet);
 }
 document.write('<a href="' + thisMenu[x].linkb + '" class="sidesub">' + thisMenu[x].name + '</a><span><br>');
}
}

// closes menu section - do not alter
function closeMenu(cat,pass) {
		//alert ("In close Menu for "+ cat)
this.cat = cat;
this.pass = pass;
document.write('<span class = "level1">');

if (cat == 'Investment Management'){
   document.write('<a href = "http://www.morganstanley.com/msim" target="_top" class="sidehead">');
}
else if (cat == 'US Liquidity'){
	document.write('<a href = "' + relativeprefix + 'msil/index.html" target="_top" class="sidehead">');
}
else if (cat == 'Products'){
   document.write('<a href = "' + relativeprefix + 'products/index.html?page=prod" target="_top" class="sidehead">');
}
else if (cat == 'Publications'){
   document.write('<a href =  "' + relativeprefix + 'publications/index.html?page=publications" target="_top" class="sidehead">');
}
else if (cat == 'About Morgan Stanley &nbsp;&nbsp;Investment&nbsp;Management'){
   document.write('<a href =  "' + relativeprefix + 'about/index.html?page=about" target="_top" class="sidehead">');
}
else if (cat == 'Client Resources'){
   document.write('<a href =  "' + relativeprefix + 'resources/index.html?page=resources" target="_top" class="sidehead">');
}
else if (cat == 'Glossary'){
   document.write('<a href =  "' + relativeprefix + 'glossary/index.html?page=glossary" target="_top" class="sidehead">');
}
else if (cat == 'Legal'){
   document.write('<a href =  "' + relativeprefix + 'legal/index.html?page=legal" target="_top" class="sidehead">');
}
else if (cat == 'Contact Us'){
   document.write('<a href =  "' + relativeprefix + 'contact/index.html?page=contactus" target="_top" class="sidehead">');
}

else{
//alert ("In close Menu (else) for "+ cat)
document.write('<a href = "' + thisPage + '?page='+pass+'" class="sidehead" target="_top">');
}
if (lev1img=='yes') {
document.write('<img src="' + imgPath + lev1ClosName +'" width="' + lev1ClosWidth + '" height="' + lev1ClosHeight + '"border="0">');
}
document.write(cat + '</a><span><br>');
}

function printLink(cat,pass) {
this.cat = cat;
this.pass = pass;
document.write('<span class = "level1">');
document.write('<a href = "' + pass+'" class="sidehead" target="_top">');
if (lev1img=='yes') {
document.write('<img src="' + imgPath + lev1ClosName +'" width="' + lev1ClosWidth + '" height="' + lev1ClosHeight + '"border="0">');
}
document.write(cat + '</a><span><br>');
}
