// JavaScript Document


function quickSearch(what,where) {
	// general search
	document.getElementById('what').value=what;
	document.getElementById('where').value=where;
	document.pcsearch.submit();
}


function viewLocation(loc) {
// submit a form to directory search
locations=new Array();
location[0]='Brentwood';
location[1]='Billericay';
location[2]='Wickford';
location[3]='Basildon';
location[4]='Corringham';
location[5]='Stanford Le Hope';
location[6]='Chadwell St Mary';
location[7]='Tilbury';
location[8]='Grays';
location[9]='Stifford Clays';
location[10]='Orsett';
location[11]='South Ockendon';
location[12]='Aveley';
location[13]='Chafford Hundred';
location[14]='West Thurrock';
location[15]='Purfleet';
location[16]='Laindon';
location[17]='Langdon Hills';
location[18]='Pitsea';
location[19]='Vange';
location[20]='Doddinghurst';
location[21]='Ingatestone';
location[22]='Ingrave';
location[23]='Shenfield';

document.getElementById('source').value='map';

var dw=document.getElementById('whereMap');
dw.value=location[loc];
document.serviceSearch.submit();
}

function ytVid(n) {
var flashvars = {};
var params = {};
var attributes = {};
attributes.id = "youtubevideo";

var vidArr=new Array("iO1fxVzS31g","sXAlpHSI-d0","JndtG8Y7yfw","0hySFt8O11A","ZvsVgu4Bgi4");

var vsrc="http://www.youtube.com/v/"+vidArr[n]+"&amp;hl=en&amp;fs=1&amp;rel=0";

swfobject.embedSWF(vsrc, "youtubevideo", "425", "344", "8.0.0", false, flashvars, params, attributes);
	
}


