
// ScriptGenerated =  ifModifiedSince =  sVar=ScriptGenerated

function ParseHiglitedMenu(mText,addDash){
	/*if(mText.toString().toLowerCase() == m_HiglitedMenuName.toString().toLowerCase()) {
		mText = "<span style=\"color: " + m_HiglitedColor + "\">" +   mText + "</span>";
	}*/
  	if(addDash) mText += " &nbsp;<span class=\"XmenuDash\">//</span>";
	return mText;
}


// ScriptGenerated =  ifModifiedSince = 
function getJspURL(jspURI){
	if ( leftJspRoot.substr(0,webRoot.length)==webRoot)
		return webRoot+  "/includes/gateway.asp?redirectPage=" + escape(jspURI) ;
	else
		return webRoot+  "/includes/gateway.asp?redirectPage=" + escape(leftJspRoot + jspURI) ;
}
function gotoJspURL(jspURI){
	document.location.href=getJspURL(jspURI);
}
function gotoURL(uri){
	document.location.href=webRoot + uri;
}
function gotoSURL(uri){
	document.location.href=webSRoot + uri;
}

    var imageRoot    = "http://www.brainfuse.com/images";
    var webRoot      = "http://www.brainfuse.com";
    var webSRoot	= "https://www.brainfuse.com";
    var l_userType	 = "-1";
    var bannerTxt = '';
     var imageHeader = "";

    webfxMenuUseHover = true;
    webfxMenuHideTime = 500;
    webfxMenuShowTime = 200;
    webfxMenuImagePath	= imageRoot + "/";
    webfxMenuDefaultWidth   = 150;
    var menuBar     = new WebFXMenuBar;


// Begin Header Portion Writing =============================================================================================
    //document.write ("<div style='position: relative;height: 100px'>");
    document.write ("<table id='tblHeader' cellspacing='0' cellpadding='0'  class='pageOutSize tblHeader' border=0>");
    document.write ('<tr>');
    document.write ("	<td width ='242'   valign='top' align='left'>");
    document.write ("<img id='imgHeader'  height='100' width='242' src='" + imageRoot + "/spacer.gif' border='0'/></td>");

    document.write ("	 <td id='tdempty' align='left' valign='top' >");
    document.write ("<table border='0'  style='height:100%;' width='100%' cellpadding='3' cellspacing='4'><tr><td   align='left' class='txtSmallLink' valign='bottom' nowrap='nowrap'>");

    document.write (bannerTxt);
document.write ("</td><td  align='right' valign='bottom'>");

/// writing the login or the signout button

	document.write ('<a class="btn" href="'  + webRoot + '/login/index.asp"><div class="btn-common btn_abs btnLeft"></div>' +
					'<div class="btn-common btnMiddle">Login Here</div>'+
					'<div class="btn-common btn_abs btnRight"></div></a>')

document.write ("");

document.write ("</td></tr></table>");

document.write ("</td>");

document.write ("	<td  id ='tdbanner' valign='top'> ");

	//document.write ("		<a href='" + webRoot + "/help/regInfo.asp'> </a>");



document.write(" </td>");
document.write ('</tr>');
document.write ('</table>');
//document.write ('</div>');

document.write ('<table class="topEdge" cellspacing="0" cellpadding="0"><tr><td></td></tr></table>');


var openingTopNavBar ="<div id='divTopNavMenu' class='topNavTitle' ><table id=tblheaderInside   cellpadding=2 cellspacing=0 class='pageInnerSize topNavTitle'><tr> " ;
openingTopNavBar +="<td align=center valign=middle  > ";
var closingTopNavBar = "</td></tr></table>";///  holding the html closing tag for the top nav bar in case no user logged
document.write(openingTopNavBar );
// Begin Menu Items Portion Writing =============================================================================================


  	var NAMenu = new WebFXMenuBar;
    
	    NAMenu.add( new WebFXMenuButton( ParseHiglitedMenu("HOME", true), "http://www.brainfuse.com/index.asp"));
     
        NAMenu.add( new WebFXMenuButton(  ParseHiglitedMenu("LIBRARIES", true)  , "/Home/INDEXLIB.ASP"));
        NAMenu.add( new WebFXMenuButton(  ParseHiglitedMenu("SCHOOLS", true) , "/Home/HomeNCLB.asp"));
        NAMenu.add( new WebFXMenuButton( ParseHiglitedMenu("COLLEGES & UNIVERSITIES", true) , "/Home/HomeColl_Univ.asp"));
        
     
    	NAMenu.add( new WebFXMenuButton( ParseHiglitedMenu("CONTACT US", true) , "/company/contactus.asp"));
    
    
    document.write(NAMenu);	
    
   // Closing The html tables
    document.write(closingTopNavBar);
document.write ("</div>");
/*    document.write ("</td>");
    document.write ('		</tr>');
    document.write ('		</table>');
    document.write ('	</td>');
    document.write ('</tr>');
    document.write ('</table>');*/
 //========================================================================================================================================
addEvent(window, "load", function(){
	var holidayRequest	= new AjaxRequest({url:"/jsp/calendar/holidays.jsp?a_id=", 
			onsuccess:function(xmlHttp){
				var xml=xmlHttp.responseXML;
				var l = xml.getElementsByTagName("message");
				if (l.length> 0 ){
					var m		= l.item(0);
					if ( m.getAttribute("status")=="-1"){
						var div 	= document.createElement("div");
						var b		= document.getElementById("tdMainContent");
	
						b.insertBefore(div, b.firstChild);
						div.className="errMsg";			
						div.appendChild(document.createTextNode(m.firstChild.data));
					}
				}
				
			},onerror:function(xmlHttp){
				
			}	
		});
		holidayRequest.send();
	});

