function  ClrSrFm(){
 if  (document.SrcFrm.Srch.value=="Search" || document.SrcFrm.Srch.value=="Recherche"){document.SrcFrm.Srch.value=""}  

}


function RdCk(){
  var Ckie=unescape(document.cookie);
  USA=Ckie.indexOf("USA");
  Canada=Ckie.indexOf("Canada");
  english=Ckie.indexOf("english");
  french=Ckie.indexOf("french");
  spanish=Ckie.indexOf("spanish");
  mexico=Ckie.indexOf("mexico");
  if (USA != "-1") {
    if (mexico != "-1"){
    document.Flag.src="jpg/mexicoflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
    else{
    if (spanish != "-1"){
      document.Flag.src="jpg/usaflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
    else{
      document.Flag.src="jpg/usaflag.jpg";
      document.SrcFrm.Country.selectedIndex=2}}}

  if (Canada != "-1") {
    if (french != "-1"){
      document.Flag.src="jpg/canadaflag.jpg";
    document.SrcFrm.Country.selectedIndex=3}
    else{
      document.Flag.src="jpg/canadaflag.jpg";
      document.SrcFrm.Country.selectedIndex=1}}


  if (USA=="-1" && Canada=="-1"){
    if (mexico != "-1"){document.Flag.src="jpg/mexicoflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
    else
    {
    document.Flag.src="jpg/noflag.jpg";
     document.SrcFrm.Country.selectedIndex=0}}


CrntDte = new Date();
  ExpDte= new Date(CrntDte.getTime() + 1000*60*60*24*365);
var cookiename="PrtCount";
 var cookiestring=""+document.cookie;
 var index1=cookiestring.indexOf(cookiename);
 var index2=cookiestring.indexOf(';',index1);
 if (index2==-1) index2=cookiestring.length; 
 VstCnt = unescape(cookiestring.substring(index1+cookiename.length+1,index2));
if (VstCnt=="NaN"){VstCnt="-1"}
 VstCnt = (eval(VstCnt) + 1);
  document.cookie='PrtCount=' + VstCnt + '; expires=' + ExpDte.toGMTString() + '; path=/';

CntryMenus();
}

function RdCk3(){
  var Ckie=unescape(document.cookie);
  USA=Ckie.indexOf("USA");
  Canada=Ckie.indexOf("Canada");
  english=Ckie.indexOf("english");
  french=Ckie.indexOf("french");
  spanish=Ckie.indexOf("spanish");
  mexico=Ckie.indexOf("mexico");
  if (USA != "-1") {
   if (mexico != "-1") {document.Flag.src="jpg/mexicoflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
    else{
    if (spanish != "-1"){
      document.Flag.src="jpg/usaflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
    else{
      document.Flag.src="jpg/usaflag.jpg";
      document.SrcFrm.Country.selectedIndex=2}}}

  if (Canada != "-1") {
    if (french != "-1"){
      document.Flag.src="jpg/canadaflag.jpg";
    document.SrcFrm.Country.selectedIndex=3}
    else{
      document.Flag.src="jpg/canadaflag.jpg";
      document.SrcFrm.Country.selectedIndex=1}}


  if (USA=="-1" && Canada=="-1"){
if (mexico != "-1"){document.Flag.src="jpg/mexicoflag.jpg";
    document.SrcFrm.Country.selectedIndex=4}
else{
    document.Flag.src="jpg/noflag.jpg";
     document.SrcFrm.Country.selectedIndex=0}}
CntryMenus();
}



function ChngCntry(Cntry){
    if (Cntry!=""){
      if (Cntry=="Canadae"){Cntry2="Canada";lang="english";}
      if (Cntry=="Canadaf"){Cntry2="Canada";lang="french";}
      if (Cntry=="USAe"){Cntry2="USA";lang="english";}
      if (Cntry=="USAs"){Cntry2="USA";lang="spanish";}
      if (Cntry=="Mexico"){Cntry2="USA";lang="english";}

      CrntDte = new Date();
      ExpDte= new Date(CrntDte.getTime() + 1000*60*60*24*365);
      ExpDte2= new Date(CrntDte.getTime() + 1000*60*60*24*30);
      ExpDte3= new Date(CrntDte.getTime() - 1);
      document.cookie='Session=Country=' + Cntry2 + '; expires=' + ExpDte.toGMTString() + '; path=/';
      document.cookie='Language=' + lang + '; expires=' + ExpDte.toGMTString() + '; path=/';
      document.cookie='DistNmber=ID=&ID2=&SAI=' + '; expires=' + ExpDte2.toGMTString() + '; path=/';
if (Cntry=="Mexico"){document.cookie='mexico=5; expires=' + ExpDte2.toGMTString() + '; path=/';}
else
{document.cookie='mexico=; expires=' + ExpDte3.toGMTString() + '; path=/';}
      RdCk();}
}



function RdCk2(){
  var Ckie=unescape(document.cookie);
  USA=Ckie.indexOf("USA");
  Canada=Ckie.indexOf("Canada");
  mexico=Ckie.indexOf("mexico");

if (mexico != "-1") {document.Flag.src="jpg/mexicoflag.jpg";}
 else{  
if (USA != "-1") {
    document.Flag.src="jpg/usaflag.jpg";}
  if (Canada != "-1") {
     document.Flag.src="jpg/canadaflag.jpg";}
  if (USA=="-1" && Canada=="-1"){
    document.Flag.src="jpg/noflag.jpg";}

}}


function HiLitBtn1(Pct,Pge){

  if(Pct == "2"){
  document.Light1.src = "jpg/" + Pge + "buttonon.jpg";}
  else{document.Light1.src = "jpg/" + Pge + "buttonoff.jpg";}
}


function HiLitBtn2(Pct2,Pge){

   if(Pct2 == "2"){document.Light2.src = "jpg/" + Pge + "buttonon.jpg";}
  else{document.Light2.src = "jpg/" + Pge + "buttonoff.jpg";}
}

function HiLitBtn3(Pct3,Pge){

   if(Pct3 == "2"){document.Light3.src = "jpg/" + Pge + "buttonon.jpg";}
  else{document.Light3.src = "jpg/" + Pge + "buttonoff.jpg";}
}



function infoscroll(seed,looped){var text1 = "Welcome to GavazziOnline - Your First Source for Information                                  Team Canada, 2005 World Jr. Hockey Champions";
var text2 = "                                      Place Orders, Check Stock and Price, Download Datasheets and Manuals, and Obtain the Latest Information on New Products.";
var msg=text1+text2;var putout = " ";
        var c   = 1;
	if (looped > 1) {
		window.status="GavazziOnline (Canada), Your First Source for Information.";
	}
	else if (seed > 100) 
{
                seed--;
                var cmd="infoscroll(" + seed + "," + looped + ")";
                timerTwo=window.setTimeout(cmd,100);
        }
        else if (seed <= 100 && seed > 0) {
                for (c=0 ; c < seed ; c++) {
                        putout+=" ";
                }
putout+=msg.substring(0,100-seed);	
                seed--;
                var cmd="infoscroll(" + seed + "," + looped + ")";
                    window.status=putout;
                timerTwo=window.setTimeout(cmd,100);
        }
        else if (seed <= 0) 
{
                if (-seed < msg.length) 
{
                        putout+=msg.substring(-seed,msg.length);
                        seed--;
                        var cmd="infoscroll(" + seed + "," + looped + ")";
                        window.status=putout;
                        timerTwo=window.setTimeout(cmd,100); // 100
                }
                else {
                        window.status=" ";
			looped += 1;
			var cmd = "infoscroll(100," + looped + ")";
                       timerTwo=window.setTimeout(cmd,75); // 75
                }
        }
}