function check_empty(text) {
  return (text.length > 0); // returns false if empty
}
function check_email(address) {
  if ((address == "")
    || (address.indexOf ('@') == -1)
    || (address.indexOf ('.') == -1))
      return false;
  return true;
}
function validate_form2() {
  validity = true; // assume valid
  if (!check_empty(document.form.name.value))
  	{ validity = false; alert('Name field is empty!'); }
  if (!check_empty(document.form.lastname.value))
  	{ validity = false; alert('Last Name field is empty!'); }
	 if (!check_empty(document.form.address.value))
  	{ validity = false; alert('Address field is empty!'); }
		 if (!check_empty(document.form.telefono.value))
  	{ validity = false; alert('Telephone field is empty!'); }
  if (!check_email(document.form.email.value))
  	{ validity = false; alert('Email address is invalid!'); }
  if (validity)
  	alert ("THANK YOU."
  		+ "We will send you further information"
  		+ " as soon as possible.");
  return validity;
}

function scrivi() {
document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='384' height='578' id='tech' align='middle'><param name='allowScriptAccess' value='sameDomain' /><param name='movie' value='servicesf.swf?xml_path=destinations.xml' /><param name='quality' value='high' /><embed src='servicesf.swf?xml_path=destinations.xml' quality='high' width='384' height='578' name='tech' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' /></object>"); }

function scrivi2() {
document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='703' height='483' id='tech' align='middle'><param name='allowScriptAccess' value='sameDomain' /><param name='movie' value='servicesf.swf?xml_path=intro.xml' /><param name='quality' value='high' /><embed src='servicesf.swf?xml_path=intro.xml' quality='high' width='703' height='483' name='tech' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' /></object>"); }
function scrivi3() {
document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='384' height='578' id='tech' align='middle'><param name='allowScriptAccess' value='sameDomain' /><param name='movie' value='servicesf.swf?xml_path=services.xml' /><param name='quality' value='high' /><embed src='servicesf.swf?xml_path=services.xml' quality='high' width='384' height='578' name='tech' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' /></object>"); }
function scrivi4() {
document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='384' height='578' id='tech' align='middle'><param name='allowScriptAccess' value='sameDomain' /><param name='movie' value='servicesf.swf?xml_path=venues.xml' /><param name='quality' value='high' /><embed src='servicesf.swf?xml_path=venues.xml' quality='high' width='384' height='578' name='tech' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' /></object>"); }
