
ns = (document.layers)? true:false;
ie = (document.all)? true:false;

function loadiframe(page)
 {
    
    if (ns)
    {
        document.frameDiv.src = page;
    }
    else if(ie)
    {
        window.document.textFrame.location = page;
    }
}

function bookmarkPIMCO()
{
	if (navigator.appName == 'Microsoft Internet Explorer' && parseInt(navigator.appVersion) >= 4)
	{
		window.external.AddFavorite(top.location.href,top.document.title);
	}
	else
	{
		if(navigator.appName == "Netscape")
			alert("Please press CTRL+D to bookmark");
	}
}


function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}


function moveme(){
if (document.images)
    top.location.replace("http://www.pimcoadvisors.com");
else
    top.location.href = "http://www.pimcoadvisors.com";
}


function winPop(URL,winW,winH)
{
	window.open(URL,'','toolbar=0,scrollbars=1,location=0,status=0,menubar=0,resizable=1,width='+winW+',height='+winH+',left=10,top=10').focus();
}


function popUp(url,wide,tall,left,top) {
popupwin=window.open(url,'win','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,width=' + wide + ',height=' + tall + ',left=' + left + ',top=' + top + ', resizable=1');
if (popupwin.opener == null) popupwin.opener = window; 
    popupwin.opener.name = "opener";
setTimeout("popupwin.focus()",100);  
}		 
		 
		 
function cntChars(ct,fld){
if(fld.value.length == ct){
alert("You have entered the maximum number of characters for this field.")
}
 if(fld.value.length > ct){
   fld.value = fld.value.slice(0,ct);
}
}

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");
            }
            
            
function mouseOver(img)
{
	if (document.images)
	{
		document.images[img].src = eval(img + "_on.src");
	}
}

function mouseOff(img)
{
	if (document.images)
	{
		document.images[img].src = eval(img + "_off.src");
	}
}

function winopener(url) {
					opener.top.location.href=url;
					opener.focus();
					self.close();
					}	
					
function TechSupportEmail()
        {
            //Used to hide the email address to avoid spam
            user = "support_technical";
            domain = "pimco.com";
            top.location.href='mailto:' + user + '@' + domain;
        }
        
function printDetail(strAppPath)//other args after strAppPath are items to show - varargs length
		{
            var args = printDetail.arguments;
			//if no content at all
			if(args.length < 1)
			{
				alert("Please use the 'Print' function in your browser menu to print this page.");
				return;
			}
			w = window.open('','newwin','width=625,scrollbars=1,resizable=1');
			w.document.write('<html><head><title>' + document.title + '</title>');
			w.document.write('<link rel="stylesheet" type="text/css" href="' + strAppPath + '/CSS/style.css"></head><body>');
			w.document.write('<table width="550"><tr><td align="right" class="arial12pxblk">');
			w.document.write('<a href="javascript:window.close();">Close Window</a><br>');
			w.document.write('<a href="javascript:window.print();"><img src="' + strAppPath + '/Images/btn_print.gif" border="0" vspace="5"></a>');
			w.document.write('</td></tr></table>');
			for(var i=1;i<args.length;i++)
				if(document.getElementById(args[i]) != null)
				{
				   //pos firefox doesnt support outerHTML so have to add tables here
				    w.document.write('<table>');
				    var stripped = (document.getElementById(args[i]).innerHTML).replace(/<a[^>]*>/ig,"");
					w.document.write(stripped);
					w.document.write('</table>');
				}
			w.document.write( '</body></html>');
			w.document.close();		
			}

	     