<!--

var DisplayText = ""


function getstuff()
{
var locate = window.location;
var text = ""+locate;
var searchword = delineate(text);
AdjustMonth = searchword;
if (AdjustMonth=="") AdjustMonth= "+0";
}

function delineate(str){
theleft = str.indexOf("#") + 1;
theright = str.indexOf("=");
return(str.substring(theleft, theright));
}


var ImageAction = "";

function SetImage(ImageID){

churchimages = new Array();
churchimages[0]="smalleb.jpg";
churchimages[1]="smalleb1.jpg";
churchimages[2]="smalleb2.jpg";
churchimages[3]="smalleb3.jpg";
churchimages[4]="smalleb4.jpg";
churchimages[5]="smalleb5.jpg";
churchimages[6]="smalleb6.jpg";
churchimages[7]="smalleb7.jpg";

DateToday=new Date()

if (DateToday.getMonth()==11) {
     ImageID.src="smallebdec.jpg";
     ImageAction="NewWindow('http://www.howe-two.com/fish/advent/index.htm','name','600','550','auto')";
     ImageID.style.cursor='hand';}
else {
     ImageAction="";
     RandomNumber = GetRandom(0,eval(churchimages.length-1));
     ImageID.src=churchimages[RandomNumber];
     ImageID.style.cursor='auto';}

}


    function GetRandom(start,end) {
    if (isNaN(start) || isNaN(end)) alert("Please input valid integer values.");
    else return  Math.floor( Math.random() * eval(end-start+1) ) + eval(start);  }




function EventWindow(Text){
var w = 640; //window width
var h = 480; //window height
var myname = "MyWindow" //name for the new window based on heading

LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings = 'height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars=yes,resizable,'

  OpenWindow=window.open("", "newwin", settings);
  OpenWindow.document.write("<html><head><TITLE>Calendar Details</TITLE>\n")
  OpenWindow.document.write("<link rel=StyleSheet href='../style1.css'>\n")
  OpenWindow.document.write("</head>\n<body style=overflow:auto;margin:10px;text-align:center;>\n\n")
  OpenWindow.document.write("<p>"+Text+"</p>\n")
  OpenWindow.document.write("<br>\n<center><input type=submit OnClick='window.close()' name=Close value=Close>\n</center>\n</body>\n</HTML>")
  OpenWindow.document.close()

}



var win = null;
function NewWindow(mypage,myname,w,h,scroll){
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings =
'height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable'
win = window.open(mypage,myname,settings)
}


-->
