// All and Any button rollovers
// Welcome NetScape2 user, sorry you can't see the pretty buttons
var hasokjs = false;
// Set some variables so links have text
var Make_sure_all_the_words_are_in_the_pages_Dougall = true;
var Fetch_pages_with_any_of_these_words_Dougall = true;
var UK_News = "News";
var Weather = "Weather";
var Add_a_site = "Add";
var Help = "Help";
var About = "About";
// Set variables for IE VB flash check
var ie_flash3_installed = null;
var ie_flash4_installed = null;

if (document.images) {
// Okay we have JS1.1
// Preload the site graphics to get round the problem of slow external sources
	var imgfetch = new Image;
	var imgnewsup = new Image;
	var imgnewsdown = new Image;
	var imgweatherup = new Image;
	var imgweatherdown = new Image;
	var imgaddup = new Image;
	var imgadd2 = new Image;
	var imgadddown = new Image;
	var imghelpup = new Image;
	var imghelpdown = new Image;
	var imgbackup = new Image;
	var imgtopup = new Image;
	var imgnextup = new Image;
	var imgsendup = new Image;

	imgfetch.src = 'graphicstuff/fetchup.gif';
	imgnewsup.src = 'graphicstuff/newsup.gif';
	imgnewsdown.src = 'graphicstuff/newsdown2.gif';
	imgweatherup.src = 'graphicstuff/weatherup.gif';
	imgweatherdown.src = 'graphicstuff/weatherdown2.gif';
	imgaddup.src = 'graphicstuff/addup.gif';
	imgadd2.src = 'graphicstuff/addup2.gif';
	imgadddown.src = 'graphicstuff/adddown2.gif';
	imghelpup.src = 'graphicstuff/helpup.gif';
	imghelpdown.src = 'graphicstuff/helpdown2.gif';
	imgbackup.src = 'graphicstuff/backup.gif';
	imgtopup.src = 'graphicstuff/topup.gif';
	imgnextup.src = 'graphicstuff/nextup.gif';
	imgsendup.src = 'graphicstuff/sendup.gif';

//Now do what we are actually here for i.e. the rollovers
	hasokjs = true;
	var anyup = new Image;
	var anydown = new Image;
	var allup = new Image;
	var alldown = new Image;
	var helpblink = new Image;
	var anyblink = new Image;

	anyup.src = 'graphicstuff/anyup.gif';
	anydown.src = 'graphicstuff/anydown.gif';
	allup.src = 'graphicstuff/allup.gif';
	alldown.src = 'graphicstuff/alldown.gif';
	helpblink.src = 'graphicstuff/helpblink.gif';
	anyblink.src = 'graphicstuff/anyblink.gif';
}

// Change the images and then set the hidden field so Dougall knows what to do

function any() {
	document.searchform.anybutton.src = anydown.src;
	document.searchform.allbutton.src = allup.src;
	document.searchform.Match.value = 0;
}

function all() {
	document.searchform.anybutton.src = anyup.src;
	document.searchform.allbutton.src = alldown.src;
	document.searchform.Match.value = 1;
}

// If there are terms then pass them if requiring help etc

function go_to_page(whichpage) {
	var gohere = "/cgi-bin/dougall.cgi?Realm=All&Match=" + document.searchform.Match.value + "&Terms=" + 
document.searchform.Terms.value + "&Page=" + whichpage;
	document.location.href = gohere;
}




