
 function window_onclick() 
	{
	window.location.href = "SearchEn.htm" ;
	}

  function newWindow(fullchd2gif) 
	 {
	 fullchd2Window = window.open( fullchd2gif, 'fullchd2Win', 'width=420,height=360' )
               fullchd2Window.focus()
               }

      adImages = new Array("images/banner1.gif","images/banner2.gif","images/banner3.gif","images/banner4.gif")
        adURL = new Array("ptfriendly.com/STinfo.html","ptfriendly.com/STinfo.html","ptfriendly.com/STinfo.html","ptfriendly.com/STinfo.html")
            thisAd = 0
           imgCt = adImages.length                                                                                            

     function rotate() 
	 {
      	if (document.images) 
		 {
      		thisAd++
     		 if (thisAd == imgCt) 
			 {
        			 thisAd = 0
        			 }
       		 document.adBanner.src=adImages[thisAd]
        		 setTimeout("rotate()", 3 * 1000)
              	}
              }

       function newLocation()  
	{
             document.location.href = "http://www." + adURL[thisAd]
             }

 function  convertToCentigrade(degFahren)
   {
    var degCent ;
    degCent = 5/9 * (degFahren - 32) ;
    var div = Math.pow(degCent, decimalPlaces) ;
    var decimalPlaces = 4 ;
    degCent = Math.round(degCent * 4) / 4 ;
    var replyCent = (degFahren + "\xB0 Fahrenheit is " + degCent + "\xB0 Centigrade") ;
    return replyCent ;     
    }

  function butToCent_onclick()
   {
   var CalcBox2 = document.form2.txtCalcBox2 ;
   if  ( isNaN(CalcBox2.value) == true || CalcBox2.value == " ")
   	{
   	 CalcBox2.value = "Error Invalid Value" ;
   	}
   else
   	{
   	 CalcBox2.value = convertToCentigrade(CalcBox2.value) ;
   	}
   }
 

     function  convertToFahrenheit(degCenti)
   {
    var degFahr ;
    degFahr = (9/5 * degCenti) + 32 ;
    var div = Math.pow(degFahr, decimalPlaces) ;
    var decimalPlaces = 4 ;
    degFahr = Math.round(degFahr * 4) / 4 ;
    var replyFahr = (degCenti + "\xB0 Centigrade is " + degFahr + "\xB0 Fahrenheit") ;
    return replyFahr ;     
    }

  function butToFahr_onclick()
   {
   var CalcBox3 = document.form3.txtCalcBox3 ;
   if  ( isNaN(CalcBox3.value) == true || CalcBox3.value == " ")
   	{
   	 CalcBox3.value = "Error Invalid Value" ;
   	}
   else
   	{
   	 CalcBox3.value = convertToFahrenheit(CalcBox3.value) ;
   	}
   }
