
defaultStatus 	= 'mounsey.co.uk';
lastPage		= document.referrer
amazonCO1	= 'http://www.amazon.co.uk/exec/obidos/ASIN/';
amazonCO2	= '/mounse';



/* Previous Page */

function previous() { history.go(-1); }

/* caption something */

function cap(pageItem) { pageItem.title = pageItem.innerText; }



/* Indicate Previous Page */

function setReferrer()			{ document.messenger.referring_page.value = lastPage; }
function showPrev(ref,steps) 	{ ref.title = "Return to ... " + lastPage; }

function printRefUrl()			{
						if (lastPage != '')
							{
							document.write('<a href="' + lastPage + '" accesskey="b" title="Your previous page (shortcut = alt+b then Enter)">'+ lastPage +'</a>');
							}
							
							else
							{
							document.write('<a href="/" accesskey="h">Home page</a>');
							}
						}


/* Indicate Link Destination url */

function showDest(dest)

{
dest.title = "Go to ... " + dest.href;
}

/* ====================================================
automatic eBay link
==================================================== */

function eBayUrl(term1,term2,term3,term4,term5)

{
document.write('<a href="'+eBay1+term1+term2+term3+term4+term5+eBay2+term1+term2+term3+term4+term5+eBay3+'" class="prodgridlink"><STRONG>List all auctions for "'+term1+term2+term3+term4+term5+'"</STRONG></a>');
}

/* ====================================================
automatic amazon.CO.UK
==================================================== */

function amazonCOurl(amazonID,prodName)

{
document.write('<a class=prodgridlink href="'+amazonCO1+amazonID+amazonCO2+'">'+prodName+'</A>');
}

/* ====================================================
Time of Day Greeting
==================================================== */

function greet()

{
today		= new Date
today_time	= today.getHours()
period		= 'Day'


if	(today_time < 12)	{ period = "morning";	}
else if (today_time < 18)	{ period = "afternoon";	}
else					{ period = "evening";		}

document.write(period);
}

/* ====================================================
Banner ads code
==================================================== */

function bannerList(a,b,c)
{   
this[0] = a;
this[1] = b;
this[2] = c;
}
   
function chooseBanner(list)

{
var today 	= new Date();
var page 	= today.getSeconds() % bannerList.length;
var starter	= "<IFRAME SRC=/sys/banners/"
var ender	= ".html NAME=ibanner CLASS=ibanner marginwidth=0 marginheight=0 scrolling=no frameborder=0 hspace=0 vspace=0></IFRAME>"
document.write(starter + list[page] + ender);
}

banners = new bannerList

("01","02","03");



/* Captioning script */

function cap(obj)
{
obj.title=obj.innerText;
}



/* End of file /js/commands.js */
