		<!-- Begin
function textCounter(field, countfield, maxlimit) {
		if (field.value.length > maxlimit) // if too long...trim it!
		{
  	 		field.value = field.value.substring(0, maxlimit);
   			alert("Long text ");
		}
		// otherwise, update 'characters left' counter
		else 
		countfield.value = maxlimit - field.value.length;
}
		
function viewit(site,windownum)
{
	  window.open(site,windownum,'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=650,height=420,top=0,left=0'); 
}

function show_project(site,windownum)
{
	  window.open(site,windownum,'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=580,height=330,top=0,left=0'); 
}

function newwindow(site,windownum)
{
	  window.open(site,windownum,'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=450,height=220,top=0,left=0'); 
}

function show_block(block_id)
{
var elm = document.getElementById(block_id);
if (elm.style.display == "none")
	elm.style.display = "block";
else 
	elm.style.display = "none";
}

function hide_block(block_id)
{
var elm = document.getElementById(block_id);
elm.style.display = "none";
}

function loading_trick()
{
show_block('upload'); // Hide Uploading Form
show_block('process'); // Show Loding msg
document.uploadform.submit();
}

function event_other1()
{
if (document.form1.event_type.value == 'other'){
	var elm = document.getElementById('event_other_subject');
	elm.style.display = "block";
}
else {
	var elm = document.getElementById('event_other_subject');
	elm.style.display = "none";
	}
}

function is_other()
{
if (document.contact_form.subject.value == 1){
	var elm = document.getElementById('other_subject');
	elm.style.display = "block";
}
else {
	var elm = document.getElementById('other_subject');
	elm.style.display = "none";
	}
}

function show_baths_text()
{
if (document.form1.bathroom.value == 'standard'){
	var elm = document.getElementById('baths');
	elm.style.display = "block";
}
else {
	var elm = document.getElementById('baths');
	elm.style.display = "none";
	}
}

function suggested_bathrooms()
{
var space = document.getElementById('people');
people = space.value ; 
bath = Math.round(people / 40) ;
var elm = document.getElementById('num_baths');
elm.value = bath ;
}

function suggested_space()
{

sittting1 = document.form1.sitting.value ; 
people1 = document.form1.people.value ;

ss = 0 ;
if (sittting1 == "rtws") // rtws == Round Tables With Stages
	ss = people1 * 3 ; 
else if ((sittting1 == "benches") || (sittting1 == "facing_long") || (sittting1 == "rt")) // rt == Round Tables 
	ss = people1 * 2.5 ;
else if ((sittting1 == "facing") || (sittting1 == "perpendicular")) 
	ss = people1 * 2 ;

document.form1.space.value = Math.round(ss) ;
suggested_bathrooms();
}

function is_ksa()
{
var elm = document.getElementById('country');
if (elm.value == "sa")
	show_block('city_div');
else 
	hide_block('city_div');
}

function goat_get_length(lorw)
{
if (lorw == 'length')
	document.form1.f_length.value = document.form1.slength.value  ;
else if (lorw == 'width') {
	document.form1.f_width.value = document.form1.swidth.value  ;
	document.form1.fire_width.value = document.form1.swidth.value * 0.5 ;
}
}

function change_url()
{
window.location = document.form1.su_agent_s.value
}

function checkEnter(e){ //e is event object passed from function invocation
var characterCode literal character code will be stored in this variable

if(e && e.which){ //if which property of event object is supported (NN4)
e = e
characterCode = e.which //character code is contained in NN4's which property
}
else{
e = event
characterCode = e.keyCode //character code is contained in IE's keyCode property
}

if(characterCode == 13){ //if generated character code is equal to ascii 13 (if enter key)
document.forms[0].submit() //submit the form
return false 
}
else{
return true 
}

}

//  End -->