
function allReplaceText(string,text,by) {
// Replaces text with by in string
    var strLength = string.length, txtLength = text.length;
    if ((strLength == 0) || (txtLength == 0)) return string;
    var i = string.indexOf(text);
    if ((!i) && (text != string.substring(0,txtLength))) return string;
    if (i == -1) return string;
    var newstr = string.substring(0,i) + by;
    if (i+txtLength < strLength)
      newstr += allReplaceText(string.substring(i+txtLength,strLength),text,by);
    return newstr;
}
// End allReplaceText
//
function check(fieldname,element,fieldtype) {
switch(fieldtype) {
case 'TEXT':
if(element.value=='') return fieldname+'\n';
break;
case 'SELECT':
if(element.selectedIndex < 1) return fieldname+'\n';
break;
case 'RADIO':
OK=false;
for (i=0;i<element.length;i++) {
if (element[i].checked) OK=true;
}
if (!OK) {
return fieldname+'\n';
}
break;
case 'CHECKBOX':
var retArr = new Array();
var lastElement = 0;
if (element[0]) { // if the button group is an array (one check box is not an array)
for (var i=0; i<element.length; i++) {
if (element[i].checked) {
retArr.length = lastElement;
retArr[lastElement] = i;
lastElement++;
}
}
} else { // There is only one check box (it's not an array)
if (element.checked) { // if the one check box is checked
retArr.length = lastElement;
retArr[lastElement] = 0; // return zero as the only array value
}
}
if(retArr.length==0) return fieldname+'\n';
break;
default:
if(element.value=='') return fieldname+'\n';
break;
}
return '';
}
// End check
//
function customcheckB()
{
var use =  'Contact Details';
if ((document.forms['Enquiries'].Question12.value=='')&&(document.forms['Enquiries'].Question13.value=='')&&(document.forms['Enquiries'].Question14.value=='')) return use;
else
return'';
}
// End customcheckB
//
function customcheckC(formname,QaName,QbName,QcName)
{
var checkFields = customcheck(formname,QaName,QbName,QcName);
if (checkFields == '') {
return customcheckD(formname, 'Question11');
} else {
return checkFields;
}
}
// End customcheckC
//
function customcheckD(formname,fieldname)
    
   {
   var use =  'Numero de telefono debe ser numerico';
   var strValidChars = "0123456789.-";
   var strChar;
   var blnResult = true;
   var strString = eval('document.forms[\''+formname+'\'].'+fieldname+'.value');
  
   if (strString.length == 0) return '';   
   //  test strString consists of valid characters listed above
   for (i = 0; i < strString.length && blnResult == true; i++)
      {
      strChar = strString.charAt(i);
      if (strValidChars.indexOf(strChar) == -1)
         {
         blnResult = false;
         }
      }
if (blnResult == false) {
return use;
} else {
return '';
}
   }
// End customcheckD
//
function customcheck(formname,QaName,QbName,QcName)
{
var use =  'Contact Details';
if ((eval('document.forms[\''+formname+'\'].'+QaName+'.value')=='')&&(eval('document.forms[\''+formname+'\'].'+QbName+'.value')=='')&&(eval('document.forms[\''+formname+'\'].'+QcName+'.value')=='')) return use;
else
return'';
}
// End customcheck
//
function doNewsQuery()
{
var s="";
var q = document.forms['newssearch'].QueryText;
var use =  q.value;
if (document.forms['newssearch'].NewsCategory)
{
var catindex = document.forms['newssearch'].NewsCategory.selectedIndex;
var cat = document.forms['newssearch'].NewsCategory.options[catindex].value;
}
else
{
var cat = "News";
}
var lang = document.forms['newssearch'].Language.value;
var ref = document.forms['question'].NID.value;
if (use == '') 
{
alert('Please enter the terms to search for.');
}
else 
{
var parsed = allReplaceText(use,' and ','%20and%20') ;
var parsed = allReplaceText(parsed,'%20AND%20','%20AND%20') ;
var parsed = allReplaceText(parsed,' & ','%20%26%20') ;
var parsed = allReplaceText(parsed,' or ',' ') ;
var parsed = allReplaceText(parsed,' OR ',' ') ;
var parsed = allReplaceText(parsed,'  ',' ') ;
var searchArgs = new Array();
searchArgs = explode(parsed,' ');
for(var k=0 ;k < searchArgs.length ; k++){
  s+="("+searchArgs[k]+")"+ ((k==searchArgs.length-1)?"":"AND");
}
 
document.forms['newssearch'].Query.value=s;
location='/SearchNews/Count=5&Start=1&SearchFuzzy=False&SearchWV=False&Query=((([Body]='+s+')OR([Name]='+s+')OR([AlternativeTitle]='+s+')OR([Abstract]='+s+'))AND([SpecialType]='+cat+'))AND([Language]=('+lang+')OR[MultiLingual]=('+lang+'))&thislang='+lang+'&link='+ref;
}
}
// End doNewsQuery
//
function doQuestionQuery()
{
var s="";
var q = document.forms['question'].QueryText;
var use =  q.value;
var lang = document.forms['question'].Language.value;
var ref = document.forms['question'].NID.value;
if ((use == '') || (use == ' Site search'))
{
alert('Please enter the terms to search for.');
}
else 
{
var parsed = allReplaceText(use,' and ','%20and%20') ;
var parsed = allReplaceText(parsed,'%20AND%20','%20AND%20') ;
var parsed = allReplaceText(parsed,' & ','%20%26%20') ;
var parsed = allReplaceText(parsed,' or ',' ') ;
var parsed = allReplaceText(parsed,' OR ',' ') ;
var parsed = allReplaceText(parsed,'  ',' ') ;
var searchArgs = new Array();
searchArgs = explode(parsed,' ');
for(var k=0 ;k < searchArgs.length ; k++){
  s+="("+searchArgs[k]+")"+ ((k==searchArgs.length-1)?"":"AND");
}
 
document.forms['question'].Query.value=s;
//location='/8025717E003B3968/SearchAllPages?Searchview&Count=5&Start=1&SearchFuzzy=False&SearchWV=False&Query=(([Body]='+s+')OR([DocTitle]='+s+')OR([Abstract]='+s+')OR([Section]='+s+')OR([Subsection]='+s+'))AND([Language]=('+lang+'))&thislang='+lang;
location='/SearchAllPages/Count=5&Start=1&SearchFuzzy=False&SearchWV=False&Query=(([Body]='+s+')OR([Name]='+s+')OR([AlternativeTitle]='+s+')OR([Abstract]='+s+')OR([Section]='+s+')OR([Subsection]='+s+'))AND([Language]=('+lang+'))&thislang='+lang+'&link='+ref;
}
}
// End doQuestionQuery
//
function explode(incoming, sep) {
var result = new Array();
var lastCh;
var inWord=false;
var k=0, words=0;
do{
var thisCh = incoming.substring(k,++k);
if (thisCh!=sep) {
    if ((words==0) & (result[words]== null)) result[words]="";
    if (lastCh == sep) {
          words++;
          result[words]="";
         }
         result[words]+=thisCh;
         }
lastCh = thisCh;
}
while(k < incoming.length)
//alert("words in result = "+result.length);
//for(var k=0; k < result.length;k++) alert(result[k]);
return result;
}
// End explode
//
function menu_over(sel_id,mn_id){
var menus = new Array(2);
menus[0]="plot4tab1_outer_menu_container";
menus[1]="plot4tab2_outer_menu_container";
if(document.getElementById(menus[mn_id])&&document.getElementById(menus[sel_id])){
 		 document.getElementById(menus[sel_id]).style.display="none";
 		 document.getElementById(menus[mn_id]).style.display="block";
}
}
// End menu_over
//
function Popup(url) {
var popup = window.open(url,'Popup','scrollbars=yes,height=700,width=660');
popup.focus();
}
// End Popup
//
function SearchQuick(){
var q = document.forms['QSearch'].QuickSearch.selectedIndex;
var full = document.forms['QSearch'].QuickSearch.options[q].value;
var target = '';
var url = '';
len = full.length;
startpos = full.indexOf("+");
if (startpos == -1)
    { var url = full;}
else
    { var target = full.substring(startpos+1, len);
      var url = full.substring(0, (len-target.length)-1);
    }
if (q !== 0)
      {
        if (target == 'new')
            {var win = window.open(url); 
            document.here;}
        else 
            {top.location= url;};
       }
}
// End SearchQuick
//
function Select(plotnum){
;
var formname =  'Select'+plotnum;
var element =  'QuickSearch'+plotnum;
var q = eval('document.forms[\''+formname+'\'].'+element+'.selectedIndex');
var full = eval('document.forms[\''+formname+'\'].'+element+'.options[q].value');
var target = '';
var url = '';
var find = "&target=";
len = full.length;
startpos = full.indexOf(find);
if (startpos == -1)
    { var url = full;
}
else
    { var target = full.substring(startpos+find.length, len);
      var url = full.substring(0, (len-target.length)-find.length);
    }
if (q !== 0)
      {
        if (target == '_blank')
            {
var win = window.open(url); 
            document.here;}
        else 
            {top.location= url;};
       }
}
// End Select
//
function toggleLayer( whichLayer )
{
  var elem, vis;
  if( document.getElementById ) // this is the way the standards work
    elem = document.getElementById( whichLayer );
  else if( document.all ) // this is the way old msie versions work
      elem = document.all[whichLayer];
  else if( document.layers ) // this is the way nn4 works
    elem = document.layers[whichLayer];
  vis = elem.style;
  // if the style.display value is blank we try to figure it out here
  if(vis.display==''&&elem.offsetWidth!=undefined&&elem.offsetHeight!=undefined)
    vis.display = (elem.offsetWidth!=0&&elem.offsetHeight!=0)?'block':'none';
  vis.display = (vis.display==''||vis.display=='block')?'none':'block';
}
// End toggleLayer
//
var ns4 = 0, ie4 = 0, dom = 0;
// this test if the browser supports the new DOM2 (IE5+ NS6+)
dom2 = document.getElementById?true:false;
// this test if the browser supports the Netscape Layers extention DOM2 (NS4 dropped in NS6)
ns4 = (document.layers)?true:false;
// this test if the browser supports the Document.All element (IE3+)
ie4 = (document.all)?true:false;
// alert(' ie='+ie4+' ns='+ns4+' dom='+dom2);
var on = '';
// the tests for DOM2 support, then Layers, then Document.all
var bWin32IE;
if ((navigator.userAgent.indexOf("IE")
    > -1) && (navigator.platform == "Win32")) {
     bWin32IE = true;
} else {
     bWin32IE = false;
}
function checkBrowser(currElem)
{} 
// End checkBrowser
//
/********************************************************
For more info & download: http://www.ibegin.com/blog/p_ibox.html
Created for iBegin.com - local search done right
MIT Licensed Style
*********************************************************/
var indicator_img_path = "/images/indicator.gif";
var indicator_img_html = "<img name=\"ibox_indicator\" src=\""+indicator_img_path+"\" alt=\"Loading...\" style=\"width:128px;height:128px;\"/>"; // don't remove the name
var opacity_level = 8; // how transparent our overlay bg is
var ibAttr = "rel"; 	// our attribute identifier for our iBox elements
	
var imgPreloader = new Image(); // create an preloader object
function init_ibox() {
	var elem_wrapper = "ibox";          
          
	createIbox(document.getElementsByTagName("body")[0]); //create our ibox
	//	elements here start the look up from the start non <a> tags
	//var docRoot = (document.all) ? document.all : document.getElementsByTagName("*");
	
	// Or make sure we only check <a> tags
	var docRoot = document.getElementsByTagName("a");
	var e;
	for (var i = 0; i < docRoot.length - 1; i++) {
			e = docRoot[i];
			if(e.getAttribute(ibAttr)) {
				var t = e.getAttribute(ibAttr);
				if ((t.indexOf("ibox") != -1)  ||  t.toLowerCase() == "ibox") { // check if this element is an iBox element
						e.onclick = function() { // rather assign an onclick event
							var t = this.getAttribute(ibAttr);
							var params = parseQuery(t.substr(5,999));
							var url = this.href;
							if(this.target != "") {url = this.target} 
	
							var title = "";
							if(showIbox(url,title,params)) {
								showBG();
								window.onscroll = maintPos;
								window.onresize = maintPos;
							}
							return false;
						}; 
						
				}
			}
     }
}
showBG = function() {
  document.getElementById("footer").style.display = 'none'; 
 
	var box_w = getElem('ibox_w');
	
	box_w.style.opacity = 0;
	box_w.style.filter = 'alpha(opacity=0)';
	setBGOpacity = setOpacity;
	for (var i=0;i<=opacity_level;i++) {setTimeout("setIboxOpacity('ibox_w',"+i+")",70*i);} // from quirksmode.org
	
		
	box_w.style.display = "";
	var pagesize = new getPageSize();
	var scrollPos = new getScrollPos();
	var ua = navigator.userAgent;
	
	if(ua.indexOf("MSIE ") != -1) {box_w.style.width = pagesize.width+'px';} 
	/*else {box_w.style.width = pagesize.width-20+'px';}*/ // scrollbars removed! Hurray!
	box_w.style.height = pagesize.height+scrollPos.scrollY+'px';
 
}
hideBG = function() {
	var box_w = getElem('ibox_w');
	box_w.style.display = "none";
document.getElementById("footer").style.display = ''; 
}
var loadCancelled = false;
showIndicator = function() {
	var ibox_p = getElem('ibox_progress');
	ibox_p.style.display = "";
	posToCenter(ibox_p);
	ibox_p.onclick = function() {hideIbox();hideIndicator();loadCancelled = true;}
}
hideIndicator = function() {
	var ibox_p = getElem('ibox_progress');
	ibox_p.style.display = "none";
	ibox_p.onclick = null;
}
createIbox = function(elem) {
	// a trick on just creating an ibox wrapper then doing an innerHTML on our root ibox element
	var strHTML = "<div id=\"ibox_w\" style=\"display:none;\"></div>";
	strHTML +=	"<div id=\"ibox_progress\" style=\"display:none;\">";
	//strHTML +=  indicator_img_html;
	strHTML +=  "</div>";
	strHTML +=	"<div id=\"ibox_wrapper\" style=\"display:none\">";
	strHTML +=	"<div id=\"ibox_content\"></div>";
	strHTML +=	"<div id=\"ibox_footer_wrapper\"><div id=\"ibox_close\" style=\"float:right;\">";
	strHTML +=	"<a id=\"ibox_close_a\" href=\"javascript:void(null);\" >Close window</a></div>";
	strHTML +=  "<div id=\"ibox_footer\">&nbsp;</div></div></div></div>";
	var docBody = document.getElementsByTagName("body")[0];
	var ibox = document.createElement("div");
	ibox.setAttribute("id","ibox");
	ibox.style.display = '';
	ibox.innerHTML = strHTML;
	elem.appendChild(ibox);
}
var ibox_w_height = 0;
showIbox = function(url,title,params) {
	
	var ibox = getElem('ibox_wrapper');
	var ibox_type = 0;
												
	// set title here
	var ibox_footer = getElem('ibox_footer');
	if(title != "") {ibox_footer.innerHTML = title;} else {ibox_footer.innerHTML = "&nbsp;";}
	
	// file checking code borrowed from thickbox
	var urlString = /\.jpg|\.jpeg|\.png|\.gif|\.html|\.htm|\.php|\.cfm|\.asp|\.aspx|\.jsp|\.jst|\.rb|\.rhtml|\.txt/g;
	
	var urlType = url.match(urlString);
	if(urlType == '.jpg' || urlType == '.jpeg' || urlType == '.png' || urlType == '.gif'){
		ibox_type = 1;
	} else if(url.indexOf("#") != -1) {
		ibox_type = 2;
	} else if(urlType=='.htm'||urlType=='.html'||urlType=='.php'||
			 urlType=='.asp'||urlType=='.aspx'||urlType=='.jsp'||
			 urlType=='.jst'||urlType=='.rb'||urlType=='.txt'||urlType=='.rhtml'||
			 urlType=='.cfm') {
		ibox_type = 3;
	} else {
                              ibox_type = 3;
		// override our ibox type if forced param exist
		//if(params['type']) {ibox_type = parseInt(params['type']);}
		//else{hideIbox();return false;}
	}
	
	ibox_type = parseInt(ibox_type);
	switch(ibox_type) {
		
		case 1:
			showIndicator();
			
			imgPreloader = new Image();
			
			imgPreloader.onload = function(){
	
				imgPreloader = resizeImageToScreen(imgPreloader);
				hideIndicator();
	
				var strHTML = "<img name=\"ibox_img\" src=\""+url+"\" style=\"width:"+imgPreloader.width+"px;height:"+imgPreloader.height+"px;border:0;cursor:hand;margin:0;padding:0;position:absolute;\"/>";
	
				if(loadCancelled == false) {
					
					// set width and height
					ibox.style.height = imgPreloader.height+'px';
					ibox.style.width = imgPreloader.width+'px';
				
					ibox.style.display = "";
					ibox.style.visibility = "hidden";
					posToCenter(ibox); 	
					ibox.style.visibility = "visible";
					setIBoxContent(strHTML);
				}
					
			}
			
			loadCancelled = false;
			imgPreloader.src = url;
			
			break;
		case 2:
			
			var strHTML = "";
			
			if(params['height']) {ibox.style.height = params['height']+'px';} 
			else {ibox.style.height = '280px';}
			
			if(params['width']) {ibox.style.width = params['width']+'px';} 
			else {ibox.style.width = '450px';}
		
			ibox.style.display = "";
			ibox.style.visibility = "hidden";
			posToCenter(ibox); 	
			ibox.style.visibility = "visible";
			
			getElem('ibox_content').style.overflow = "auto";
			
			var elemSrcId = url.substr(url.indexOf("#") + 1,1000);
			
			var elemSrc = getElem(elemSrcId);
			
			if(elemSrc) {strHTML = elemSrc.innerHTML;}
		
			setIBoxContent(strHTML);
			
			break;
			
		case 3:
			showIndicator();
                                             //add name & value pair to switch subform display
                                                 var urlswitch = url + '?opendocument&imagelib=yes';
			http.open('get',urlswitch,true);
			http.onreadystatechange = function() {
				if(http.readyState == 4){
					hideIndicator();
					
					if(params['height']) {ibox.style.height = params['height']+'px';} 
					else {ibox.style.height = '280px';}
					
					if(params['width']) {ibox.style.width = params['width']+'px';} 
					else {ibox.style.width = '450px';}
		
					ibox.style.display = "";
					ibox.style.visibility = "hidden";
					posToCenter(ibox); 	
					ibox.style.visibility = "visible";
					getElem('ibox_content').style.overflow = "auto";
				//get data	
					var response = http.responseText;
				//	var response2 = response.getElementsByID("content")[0].value;
				     
				//	alert(response2);
					setIBoxContent(response);
					
				}
			}
			
			http.setRequestHeader("Content-Type","application/x-www-form-urlencoded; charset=UTF-8");
			http.send(null);
			break;
		
		default:
			
	 } 
	 
	
	ibox.style.opacity = 0;
	ibox.style.filter = 'alpha(opacity=0)';	
	var ibox_op_level = 10;
	
	setIboxOpacity = setOpacity;
	for (var i=0;i<=ibox_op_level;i++) {setTimeout("setIboxOpacity('ibox_wrapper',"+i+")",30*i);}
	if(ibox_type == 2 || ibox_type == 3) {
		ibox.onclick = null;getElem("ibox_close_a").onclick = function() {hideIbox();}
	} else {ibox.onclick = hideIbox;getElem("ibox_close_a").onclick = null;}
	return true;
}
setOpacity = function (elemid,value)	{
		var e = getElem(elemid);
		e.style.opacity = value/10;
		e.style.filter = 'alpha(opacity=' + value*10 + ')';
}
resizeImageToScreen = function(objImg) {
	
	var pagesize = new getPageSize();
	
	var x = pagesize.width - 100;
	var y = pagesize.height - 100;
	if(objImg.width > x) { 
		objImg.height = objImg.height * (x/objImg.width); 
		objImg.width = x; 
		if(objImg.height > y) { 
			objImg.width = objImg.width * (y/objImg.height); 
			objImg.height = y; 
		}
	} 
	else if(objImg.height > y) { 
		objImg.width = objImg.width * (y/objImg.height); 
		objImg.height = y; 
		if(objImg.width > x) { 
			objImg.height = objImg.height * (x/objImg.width); 
			objImg.width = x;
		}
	}
	return objImg;
}
maintPos = function() {
	
	var ibox = getElem('ibox_wrapper');
	var box_w = getElem('ibox_w');
	var pagesize = new getPageSize();
	var scrollPos = new getScrollPos();
	var ua = navigator.userAgent;
	if(ua.indexOf("MSIE ") != -1) {box_w.style.width = pagesize.width+'px';} 
	/*else {box_w.style.width = pagesize.width-20+'px';}*/
	if(ua.indexOf("Opera/9") != -1) {box_w.style.height = document.body.scrollHeight+'px';}
	else {box_w.style.height = pagesize.height+scrollPos.scrollY+'px';}
	
	// alternative 1
	//box_w.style.height = document.body.scrollHeight+50+'px';	
	
	posToCenter(ibox);
	
}
hideIbox = function() {
	hideBG();
	var ibox = getElem('ibox_wrapper');
	ibox.style.display = "none";
	clearIboxContent();
	window.onscroll = null;
}
posToCenter = function(elem) {
	var scrollPos = new getScrollPos();
	var pageSize = new getPageSize();
	var emSize = new getElementSize(elem);
	var x = Math.round(pageSize.width/2) - (emSize.width /2) + scrollPos.scrollX;
	var y = Math.round(pageSize.height/2) - (emSize.height /2) + scrollPos.scrollY;	
	elem.style.left = x+'px';
	elem.style.top = y+'px';	
}
getScrollPos = function() {
	var docElem = document.documentElement;
	this.scrollX = self.pageXOffset || (docElem&&docElem.scrollLeft) || document.body.scrollLeft;
	this.scrollY = self.pageYOffset || (docElem&&docElem.scrollTop) || document.body.scrollTop;
}
getPageSize = function() {
	var docElem = document.documentElement
	this.width = self.innerWidth || (docElem&&docElem.clientWidth) || document.body.clientWidth;
	this.height = self.innerHeight || (docElem&&docElem.clientHeight) || document.body.clientHeight;
}
getElementSize = function(elem) {
	this.width = elem.offsetWidth ||  elem.style.pixelWidth;
	this.height = elem.offsetHeight || elem.style.pixelHeight;
}
setIBoxContent = function(str) {
	clearIboxContent();
	var e = getElem('ibox_content');
	e.style.overflow = "auto";
	e.innerHTML = str;
	
}
clearIboxContent = function() {
	var e = getElem('ibox_content');
	e.innerHTML = "";
}
getElem = function(elemId) {
	return document.getElementById(elemId);	
}
// parseQuery code borrowed from thickbox, Thanks Cody!
parseQuery = function(query) {
   var Params = new Object ();
   if (!query) return Params; 
   var Pairs = query.split(/[;&]/);
   for ( var i = 0; i < Pairs.length; i++ ) {
      var KeyVal = Pairs[i].split('=');
      if ( ! KeyVal || KeyVal.length != 2 ) continue;
      var key = unescape( KeyVal[0] );
      var val = unescape( KeyVal[1] );
      val = val.replace(/\+/g, ' ');
      Params[key] = val;
   }
   
   return Params;
}
/********************************************************
 Make this IE7 Compatible ;)
 http://ajaxian.com/archives/ajax-on-ie-7-check-native-first
*********************************************************/
createRequestObject = function() {
	var xmlhttp;
		/*@cc_on
	@if (@_jscript_version>= 5)
			try {xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
			} catch (e) {
					try {xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");}
					catch (E) {xmlhttp = false;}
			}
	@else
		xmlhttp = false;
	@end @*/
	if (!xmlhttp && typeof XMLHttpRequest != "undefined") {
			try {xmlhttp = new XMLHttpRequest();} catch (e) {xmlhttp = false;}
	}
	return xmlhttp;
}
var http = createRequestObject();
function addEvent(obj, evType, fn){ 
 if (obj.addEventListener){ 
   obj.addEventListener(evType, fn, false); 
   return true; 
 } else if (obj.attachEvent){ 
   var r = obj.attachEvent("on"+evType, fn); 
   return r; 
 } else { 
   return false; 
 } 
}
addEvent(window, 'load', init_ibox);
// End init_ibox
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_00002A5E() {
var validatelist = '';
var failed = false;
validatelist += check('I would like more information about advertising with:',document.forms['Advertise with us TC2326'].Question1,'CHECKBOX');
validatelist += check('First Name:',document.forms['Advertise with us TC2326'].Question3,'TEXT');
validatelist += check('Last Name:',document.forms['Advertise with us TC2326'].Question4,'TEXT');
validatelist += check('Company Name:',document.forms['Advertise with us TC2326'].Question5,'TEXT');
validatelist += check('Address1:',document.forms['Advertise with us TC2326'].Question6,'TEXT');
validatelist += check('City:',document.forms['Advertise with us TC2326'].Question9,'TEXT');
validatelist += check('Post code:',document.forms['Advertise with us TC2326'].Question10,'TEXT');
validatelist += customcheck('Advertise with us TC2326','Question11','Question12','Question13');;
if (validatelist.length>0) {
alert('You have left the following fields blank and they\nwill need to be completed in order to proceed:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_00002A5E
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_00002A9A() {
var validatelist = '';
var failed = false;
validatelist += check('What is your enquiry?:',document.forms['Enquiries'].Question1,'SELECT');
validatelist += check('First Name:',document.forms['Enquiries'].Question3,'TEXT');
validatelist += check('Last Name:',document.forms['Enquiries'].Question4,'TEXT');
validatelist += check('Address1',document.forms['Enquiries'].Question6,'TEXT');
validatelist += check('City',document.forms['Enquiries'].Question9,'TEXT');
validatelist += check('Post Code',document.forms['Enquiries'].Question10,'TEXT');
validatelist += check('Enquiry:',document.forms['Enquiries'].Question14,'TEXTAREA');
validatelist += customcheck('Enquiries','Question11','Question12','Question13');
if (validatelist.length>0) {
alert('You have left the following fields blank and they\nwill need to be completed in order to proceed:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_00002A9A
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_000039CA() {
var validatelist = '';
var failed = false;
validatelist += check('First Name:',document.forms['Advertiser & Customer Enquiries'].Question4,'TEXT');
validatelist += check('Last Name:',document.forms['Advertiser & Customer Enquiries'].Question5,'TEXT');
validatelist += check('Company Name:',document.forms['Advertiser & Customer Enquiries'].Question6,'TEXT');
validatelist += check('Address1:',document.forms['Advertiser & Customer Enquiries'].Question7,'TEXT');
validatelist += check('City:',document.forms['Advertiser & Customer Enquiries'].Question10,'TEXT');
validatelist += check('Post code:',document.forms['Advertiser & Customer Enquiries'].Question11,'TEXT');
validatelist += check('Enquiry:',document.forms['Advertiser & Customer Enquiries'].Question15,'TEXTAREA');
validatelist += customcheck('Advertiser & Customer Enquiries','Question12','Question13','Question14');
if (validatelist.length>0) {
alert('You have left the following fields blank and they\nwill need to be completed in order to proceed:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_000039CA
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_00003E86() {
var validatelist = '';
var failed = false;
validatelist += check('Nombre:',document.forms['Advertiser & Customer Enquiries - ES'].Question4,'TEXT');
validatelist += check('Apellido:',document.forms['Advertiser & Customer Enquiries - ES'].Question5,'TEXT');
validatelist += check('Nombre de la empresa:',document.forms['Advertiser & Customer Enquiries - ES'].Question6,'TEXT');
validatelist += check('Direccion1:',document.forms['Advertiser & Customer Enquiries - ES'].Question7,'TEXT');
validatelist += check('Ciudad:',document.forms['Advertiser & Customer Enquiries - ES'].Question10,'TEXT');
validatelist += check('Codigo postal:',document.forms['Advertiser & Customer Enquiries - ES'].Question11,'TEXT');
validatelist += check('Consulta:',document.forms['Advertiser & Customer Enquiries - ES'].Question15,'TEXTAREA');
validatelist += customcheck('Advertiser & Customer Enquiries - ES','Question12','Question13','Question14');
if (validatelist.length>0) {
alert('Ha dejado en blanco los siguientes campos y\ndebe completarlos para poder avanzar:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_00003E86
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_00003E9E() {
var validatelist = '';
var failed = false;
validatelist += check('En que consiste su consulta?:',document.forms['Enquiries - ES'].Question1,'SELECT');
validatelist += check('Nombre:',document.forms['Enquiries - ES'].Question3,'TEXT');
validatelist += check('Apellido:',document.forms['Enquiries - ES'].Question4,'TEXT');
validatelist += check('Direccion1:',document.forms['Enquiries - ES'].Question6,'TEXT');
validatelist += check('Ciudad:',document.forms['Enquiries - ES'].Question9,'TEXT');
validatelist += check('Codigo postal:',document.forms['Enquiries - ES'].Question10,'TEXT');
validatelist += check('Consulta:',document.forms['Enquiries - ES'].Question14,'TEXTAREA');
validatelist += customcheck('Enquiries - ES','Question11','Question12','Question13');
if (validatelist.length>0) {
alert('Ha dejado en blanco los siguientes campos y\ndebe completarlos para poder avanzar:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_00003E9E
//
//
// Check that required fields are filled in on questionnaire
//
function Validate_00006562() {
var validatelist = '';
var failed = false;
validatelist += check('I would like more information about advertising with:',document.forms['Advertise with us TC2326 - ES'].Question1,'CHECKBOX');
validatelist += check('Nombre:',document.forms['Advertise with us TC2326 - ES'].Question3,'TEXT');
validatelist += check('Apellido:',document.forms['Advertise with us TC2326 - ES'].Question4,'TEXT');
validatelist += check('Nombre de la empresa:',document.forms['Advertise with us TC2326 - ES'].Question5,'TEXT');
validatelist += check('Direccion1:',document.forms['Advertise with us TC2326 - ES'].Question6,'TEXT');
validatelist += check('Ciudad:',document.forms['Advertise with us TC2326 - ES'].Question9,'TEXT');
validatelist += check('Codigo postal:',document.forms['Advertise with us TC2326 - ES'].Question10,'TEXT');
validatelist += customcheckC('Advertise with us TC2326 - ES','Question11','Question12','Question13');
if (validatelist.length>0) {
alert('Ha dejado en blanco los siguientes campos y\ndebe completarlos para poder avanzar:\n\n'+validatelist);
return false;
}
else {
return true;
}
}
// End function
//
// End Validate_00006562
//
