

	var Home_path_to_files = ''
	// var Home_path_to_files = 'file://localhost/i:/aat';

  var choose_one= get_random(6);  
  choose_one--;

if (document.images)
 {
     pic1= new Image();
     pic1.src=Home_path_to_files + "/images/top1_1.gif";  
     pic2= new Image();
     pic2.src=Home_path_to_files + "/images/top2_1.gif";  
     pic3= new Image();
     pic3.src=Home_path_to_files + "/images/top3_1.gif";  
     pic4= new Image();
     pic4.src=Home_path_to_files + "/images/top4_1.gif";  
     pic5= new Image();
     pic5.src=Home_path_to_files + "/images/top5_1.gif";  
     pic6= new Image();
     pic6.src=Home_path_to_files + "/images/top6_1.gif";  
     pic7= new Image();
     pic7.src=Home_path_to_files + "/images/top1_2.gif";  
     pic8= new Image();
     pic8.src=Home_path_to_files + "/images/top2_2.gif";  
     pic9= new Image();
     pic9.src=Home_path_to_files + "/images/top3_2.gif";  
     pic10= new Image();
     pic10.src=Home_path_to_files + "/images/top4_2.gif";  
     pic11= new Image();
     pic11.src=Home_path_to_files + "/images/top5_2.gif";  
     pic12= new Image();
     pic12.src=Home_path_to_files + "/images/top6_2.gif";  
 }    

function get_random(maxNum)
{
  if (Math.random && Math.round)
  {
    var ranNum= Math.round(Math.random()*(maxNum-1));
    ranNum+=1;
    return ranNum;
  }
  else
  {
  today= new Date();
  hours= today.getHours();
  mins=   today.getMinutes();
  secn=  today.getSeconds();
  if (hours==19)
   hours=18;
  var ranNum= (((hours+1)*(mins+1)*secn)%maxNum)+1;
  return ranNum; 
  }
}

function get_Image1()
{
 if (document.images)
 {

  var pics1= new Array(6) 
   pics1[0]=pic1.src;
   pics1[1]=pic2.src;
   pics1[2]=pic3.src;
   pics1[3]=pic4.src;
   pics1[4]=pic5.src; 
   pics1[5]=pic6.src; 

  document.write("<img src='"+pics1[choose_one]+"' width='175' height='21' border='0'>");
 }
}

function get_Image2()
{
 if (document.images)
 {

  var pics2= new Array(6) 
   pics2[0]=pic7.src;
   pics2[1]=pic8.src;
   pics2[2]=pic9.src;
   pics2[3]=pic10.src;
   pics2[4]=pic11.src; 
   pics2[5]=pic12.src; 

  document.write("<img src='"+pics2[choose_one]+"' width='175' height='27' border='0'>");
 }
}

function SubmitSearch()
{
	if(document.searchform.QueryText.value=='')
	{
		alert('Please enter search query.');
		return false;
	}
	return true;
}

var gAutoPrint = true; // Flag for whether or not to automatically call the print function

function printSpecial()
{
	if (document.getElementById != null)
	{
		var html = '<HTML>\n<HEAD>\n';

		if (document.getElementsByTagName != null)
		{
			var headTags = document.getElementsByTagName("head");
			if (headTags.length > 0)
				html += headTags[0].innerHTML;
		}
		
		html += '\n</HEAD>\n<BODY class="cnorm">\n';
		
		var printReadyElem = document.getElementById("printReady");
		
		if (printReadyElem != null)
		{
				html += printReadyElem.innerHTML;
		}
		else
		{
			alert("Could not find the printReady section in the HTML");
			return;
		}
			
		html += '\n</BODY>\n</HTML>';
		
		var printWin = window.open("","printSpecial");
		printWin.document.open();
		printWin.document.write(html);
		printWin.document.close();
		if (gAutoPrint)
			printWin.print();
	}
	else
	{
		alert("Sorry, the print ready feature is only available in modern browsers.");
	}
}

