function popupon() {
      document.getElementById("popupDiv").className="popupOn";
      }
      function popupoff() {
      document.getElementById("popupDiv").className="popupoff";
      }
        
function clear(pointer) {
        var text = pointer.firstChild.data ;
        // note : strips any leading spaces!
         document.getElementById('SearList').value ='' ;
         document.getElementById('CatSel').focus() ;
        }

function localControl(e) {
        if (e.keyCode == 9) {
       document.getElementById("GFSeaDiv").className = "GFpopoff" ;
	    }
      }
      
function EWDHEAS() {
      GSear = document.getElementById('selform').value ;
      window.location.href='http://127.0.0.1/catalog/GFUS4U.php?statsearch=' + GSear ;

}

function EWDSTATS() {
      GSear = document.getElementById('statsearch').value ;
      GLang = document.getElementById('statlang').value ;
      GSEAR = GSEAR + "&Language=" + GLang ;
      window.location.href='http://127.0.0.1/catalog/GFUS4T.php?catlook=' + GSear ;

}

function GFInit(obj) {
            alert(Starting) ;
            //var popupPointer = document.getElementById('GFSeaDiva') ;
            //popupPointer.className='GFpopOn' ;
            //var y = EWD.utils.findPosY(obj) ;
            //var x = EWD.utils.findPosX(obj) ;
            //popupPointer.style.top = 120 + "px";
            //popupPointer.style.left = 400 + "px" ;
            EWD.ajax.base = "/catalog/" ;
            EWD.ajax.getFragment("GFUSInit.php","GFSeaDiva") ;
       }
      
function EWDINP(e) {
	if(window.event) // IE
	  {
	  keyp = e.keyCode;
	  }
	else if(e.which) // Netscape/Firefox/Opera
	  {
	  keyp = e.which;
	  }
       //var keyp = document.getElementById("txtgsearch").keyCode
       //alert(keyp)
       if (keyp == 13) { 
         EWDRNDS();
         }
       }
      

function dsumm() {
      //alert('Emptying dsumm') ;
       //document.getElementById('dsumm').innerHTML = ''
       }
       
function nodsumm() {
       }

function GFAlerta() {
       alert('Searet') ;
       }

function IORDCLO() {
     document.getElementById("Iorders").innerHTML="" ;
     }
     
function IORDSHO() {
     var popupPointer = document.getElementById('Iorders') ;
        popupPointer.className='Iorderon' ;
     }
      
function popup(obj) {
        var popupPointer = document.getElementById('popupDiv') ;
        popupPointer.className='popupOn' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y + 10 + "px" ;
        popupPointer.style.left = 0 + "px" ;
      }
      
function GFpopup(obj) {
        var popupPointer = document.getElementById('GFSeaDiv') ;
        popupPointer.className='GFpopOn' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = 50 + y + "px";
        popupPointer.style.left = 10 + x + "px" ;
      }
      
function GFpopupi(obj) {
        var popupPointer = document.getElementById('GFSeaDiv') ;
        popupPointer.className='GFpopOn' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y + 20 + "px";
        popupPointer.style.left = x + "px" ;
      }
      
 function popupite(obj) {
         var popupPointer = document.getElementById('itegloss') ;
         popupPointer.className='GFpopOn' ;
         var y = EWD.utils.findPosY(obj) ;
         var x = EWD.utils.findPosX(obj) ;
         popupPointer.style.top = y + 20 + "px";
         popupPointer.style.left = x + "px" ;
      }
      
 function GFpopQup(obj) {
         var popupPointer = document.getElementById('GFSeaDiva') ;
         popupPointer.className='GFpopOn' ;
         var y = EWD.utils.findPosY(obj) ;
         var x = EWD.utils.findPosX(obj) ;
         popupPointer.style.top = y + 20 + "px";
         popupPointer.style.left = x + "px" ;
      }
      
 function GFPopQClo(obj) {
 
         var popupPointer = document.getElementById('GFSeaDiva') ;
         popupPointer.className='GFpopoff' ;
      }
      
 function GFpopSup(obj) {
          alert(Starting) ;
          var popupPointer = document.getElementById('GFSeaDiva') ;
          popupPointer.className='GFpopOn' ;
          //var y = EWD.utils.findPosY(obj) ;
          //var x = EWD.utils.findPosX(obj) ;
          popupPointer.style.top = 120 + "px";
          popupPointer.style.left = 400 + "px" ;
          EWD.ajax.base = "/catalog/" ;
          EWD.ajax.getFragment("GFUSInit.php","GFSeaDiva") ;
       }
       
         
  function GFPopSClo(obj) {
  
          var popupPointer = document.getElementById('GFSeaDiva') ;
          popupPointer.className='GFpopoff' ;
      }
      
 function glossup(obj) {
        var popupPointer = document.getElementById('popupgloss') ;
        popupPointer.className='glossona' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y - 100 + "px" ;
        popupPointer.style.left = 400 + "px" ;
      }
      
 function glossupls(obj) {
         var popupPointer = document.getElementById('popupgloss') ;
         popupPointer.className='glossonals' ;
         var y = EWD.utils.findPosY(obj) ;
         var x = EWD.utils.findPosX(obj) ;
         popupPointer.style.top = y - 100 + "px" ;
         popupPointer.style.left = 400 + "px" ;
      }
      
 function maskup(obj) {
         var popupPointer = document.getElementById('popupgloss') ;
         popupPointer.className='glossona' ;
         var y = EWD.utils.findPosY(obj) ;
         var x = EWD.utils.findPosX(obj) ;
         popupPointer.style.top = y - 50 + "px" ;
         popupPointer.style.left = 450 + "px" ;
      }
      
 function spemask(obj) {
          var popupPointer = document.getElementById('spemaskf') ;
          popupPointer.className='glossonb' ;
          var y = EWD.utils.findPosY(obj) ;
          var x = EWD.utils.findPosX(obj) ;
          popupPointer.style.top = y + 30 + "px" ;
          popupPointer.style.left = 600 + "px" ;
      }
      
 function spemclo(obj) {
          var popupPointer = document.getElementById('spemaskf') ;
          popupPointer.className='glossoffb' ;
         
      }   
         
 
 function Dmessup(obj) {
          var popupPointer = document.getElementById('lsmess') ;
          popupPointer.className='messona' ;
          var y = EWD.utils.findPosY(obj) ;
          var x = EWD.utils.findPosX(obj) ;
          popupPointer.style.top = 40 + "px" ;
          popupPointer.style.left = 0 + "px" ;
      }
      
function messoff(obj) {
          var popupPointer = document.getElementById('lsmess') ;
          popupPointer.className='messoffa' ;
           
      }
      
 function hdinfoff() {
      document.getElementById("popupgloss").className="hdinfoffa";
      }
      
 function hdinfon(obj) {
        var popupPointer = document.getElementById('popupgloss') ;
        popupPointer.className='hdinfona' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y + 50 + "px" ;
        popupPointer.style.left = 400 + "px" ;
      }
      
 function shocaloff() {
       document.getElementById("shocals").className="shocaloffa";
       }
      
 function shocalon(obj) {
         var popupPointer = document.getElementById('shocals') ;
         popupPointer.className='shocalona' ;
        
      }
      
 function popupglossoff() {
      document.getElementById("popupgloss").className="glossoffa";
      }

function baskclose() {
            document.getElementById("popupgloss").className="glossoffa";
           
      }
      
 function popupgloss() {
        popupPointer = document.getElementById('popupgloss') ;
        popupPointer.className='glossona' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y + 10 + "px" ;
        popupPointer.style.left = x + 0 + "px" ;
      }
      
function GFfocusa() {
       document.getElementById('Catlook').focus() ;
      }
 
function GFlogin() {
       document.getElementById('UserName').focus() ;
      }

function ccardoff() {
      //document.getElementById("CcardDets").className="ccrdoff";
	document.getElementById('CcardDets').innerHTML="";
      }

function ccardona(obj) {
        popupPointer = document.getElementById('CcardDets') ;
        popupPointer.className='ccrdon' ;
        var y = EWD.utils.findPosY(obj) ;
        var x = EWD.utils.findPosX(obj) ;
        popupPointer.style.top = y+20 + "px" ;
        popupPointer.style.left =x-150 + "px";
      }
function ccardon(obj) {
        document.getElementById('CcardDets').style.visibility="visible";
        document.getElementById('CcardDets').style.display="";
       }

function Passask(obj) {
         var username= document.getElementById("loginUsername").value
         var usermail= document.getElementById("loginEmail").value
        
      }
      

    
function GFprintDiv(divId,height,width,top,left,title,styleSrc,autoprint,path) {
if (!height) height= "800";
if (!width) width= "780";
if (!top) top= "200";
if (!left) left= "100";
var DateTime=document.getElementById('DateTime').value ;
var domNode=document.getElementById(divId);
var params="height="+height+",width="+width;
if (navigator.appName=='Netscape') {
params=params+',ScreenX='+left+',ScreenY='+top;
}
else {
params=params+',left='+left+',top='+top+',';
}
var outputWindow;
outputWindow=window.open("","",params);
outputWindow.document.open("text/html", "replace");
if (!title) title="Print";
outputWindow.document.write("<html><head><title>"+title+"</title>\n");
outputWindow.document.write("</head><body>\n");
if (!autoprint) outputWindow.document.write("<div id='printButton'><input type='button' value='Print' onClick='document.getElementById(\"printButton\").innerHTML=\"\" ; window.print()' /><hr/></div>\n");
outputWindow.document.write("<Table width='600'><tr><td class='GFG'>Goodfellow</td><td align='right' class='bTn'>"+DateTime+"</td></tr></table>\n");
outputWindow.document.write("<div id='add'></div>\n");
outputWindow.document.write("</body></html>\n");
outputWindow.document.close();
if (styleSrc) EWD.page.addStylesheet(outputWindow.document,styleSrc);
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/global.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/layout.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/thickbox.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/GFEWD.css');
var ssObj=EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/print.css','print');
var importedMarkup=domNode.innerHTML;
outputWindow.document.getElementById('add').innerHTML=importedMarkup;
if (autoprint) {
outputWindow.print();
outputWindow.close();
}
}

function GFprintDivS(divId,height,width,top,left,title,styleSrc,autoprint,path) {
if (!height) height= "800";
if (!width) width= "780";
if (!top) top= "200";
if (!left) left= "100";
//var DateTime=document.getElementById('DateTime').value ;
//var Date=getCalendarDate() ; 
//alert Date ;
//var Time=getClockTime() ;
//var DateTime = Date + Time ;
var domNode=document.getElementById(divId);
var params="height="+height+",width="+width;
if (navigator.appName=='Netscape') {
params=params+',ScreenX='+left+',ScreenY='+top;
}
else {
params=params+',left='+left+',top='+top+',';
}
var outputWindow;
outputWindow=window.open("","",params);
outputWindow.document.open("text/html", "replace");
if (!title) title="Print";
outputWindow.document.write("<html><head><title>"+title+"</title>\n");
outputWindow.document.write("</head><body>\n");
if (!autoprint) outputWindow.document.write("<div id='printButton'><input type='button' value='Print' onClick='document.getElementById(\"printButton\").innerHTML=\"\" ; window.print()' /><hr/></div>\n");
outputWindow.document.write("<Table width='600'><tr><td class='GFG'>Goodfellow</td></tr></table>\n");
outputWindow.document.write("<div id='add'></div>\n");
outputWindow.document.write("</body></html>\n");
outputWindow.document.close();
if (styleSrc) EWD.page.addStylesheet(outputWindow.document,styleSrc);
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/global.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/layout.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/thickbox.css');
EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/GFEWD.css');
var ssObj=EWD.page.addStylesheet(outputWindow.document,'http://127.0.0.1/catalog/styles/print.css','print');
var importedMarkup=domNode.innerHTML;
outputWindow.document.getElementById('add').innerHTML=importedMarkup;
if (autoprint) {
outputWindow.print();
outputWindow.close();
}
}


