window.onerror=errorSupress;function errorSupress(){return true;}var usecode;var winpara='toolbar=yes,location=no,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,height=400,width=530';var usewin;var sorwin;var infowin;var optnum;function cShowHide(num){curStatus = document.getElementById('c'+num).style.display;if (curStatus != 'block'){document.getElementById('c'+num).style.display='block';}else{document.getElementById('c'+num).style.display='none';}}function nShow(num){document.getElementById('n'+num).style.display='block';}function nHide(num){document.getElementById('n'+num).style.display='none';}function section(sectionId){var allDivNode=document.getElementsByTagName('div');for(var divNum=0;divNum< allDivNode.length;divNum++){var divClass = allDivNode[divNum].className;if(divClass=='section'){var divId = allDivNode[divNum].id;if(divId==sectionId || (divId=='menu' && sectionId!='comm')){allDivNode[divNum].style.display='block';}else{allDivNode[divNum].style.display='none';}}}}function subsection(subsectionId){var allDivNode=document.getElementsByTagName('div');for(var divNum=0;divNum< allDivNode.length;divNum++){var divClass = allDivNode[divNum].className;if(divClass=='subsection'){var divId = allDivNode[divNum].id;if(divId==subsectionId&&subsectionId!='comm'){allDivNode[divNum].style.display='block';}else{allDivNode[divNum].style.display='none';}}}}function phpstatus(phpcheck){if(phpcheck=='nogo'){document.getElementById('up1').style.display='block';document.getElementById('up2').style.display='none';}else{document.getElementById('up1').style.display='none';document.getElementById('up2').style.display='block';if(phpcheck=='upload'){section('sect7');}}}function init(){for(var i=0;i<6;i++){document.getElementById('fldtabbod').rows[i].style.display='none';}defvars();}function openHelp(bm){var helpWin = window.open('Help.html'+ bm,'Help');helpWin.focus();}function opensoftSWOT(){var softSWOTWin = window.open('http://www.softswot.com','softSWOT');softSWOTWin.focus();}function codebuild(opt){var delsccon=false;if(!window.document.config.delemail.value){delsccon=confirm("If you do not include a delivery email address in the processing script it must be included as hidden fields in the form. Do you want to continue without a delivery email address in the processing script?");if(delsccon!=true){section('sect1');window.document.config.delemail.focus();return;}}if(window.document.config.delemail.value || delsccon==true){if(window.document.config.delemail.value){re=/^([a-zA-Z0-9])+([\.a-zA-Z0-9_-])*@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-]+)+/;var firstemailin=window.document.config.delemail.value;var inemails = firstemailin.split(',');var inemail = inemails[0];var ckemailin = re.test(inemail);if (ckemailin==false){alert("Your delivery email address "+inemail+" does not appear to be valid.");section('sect1');window.document.config.delemail.focus();return;}}optnum=opt;useBut=window.document.getElementById("build"+optnum);if(optnum==4){useBut.value="Re-Building.................................................";}else{useBut.value="Building.......";}useBut.style.color = '#ff0000';if(optnum==3){usewin=window.open(window.location.href,"usewin",winpara);var usefile=window.document.config.usefile.value;var useform="file:///"+usefile;if(usefile!=''){usewin.location.href=useform;usewin.status = "Form Layout of Existing File.";setTimeout("gethtml();",1000);}else{alert("You must select an Existing File before you can Build Form.");window.document.config.usefile.focus();}}else if(optnum==4){usewin=window.open(window.location.href,"usewin",winpara);var pagecode=window.document.config.pagecode.value
 if(pagecode!=''){usewin.document.open("text/html");usewin.document.write(pagecode);usewin.document.close();usewin.status = "Form Layout of Page Layout Code.";setTimeout("gethtml();",1000);}else{alert("You must have Form Page Layout Code (generated when you Build Form) before you can Re-Build Using Form Page Layout Code.");window.document.config.pagecode.focus();}}else{usecode = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\n<html xmlns="http://www.w3.org/1999/xhtml">\n';usecode+='<head>\n<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />\n<meta name="Copyright" content="Copyright www.softswot.com"/>\n<link rel="icon" href="http://www.softswot.com/favicon.ico"/>\n<link rel="shortcut icon" href="http://www.softswot.com/favicon.ico"/>\n<title>Form - powered by Form1 from www.softswot.com</title>\n';var usecss=window.document.config.cssfile.value;if(usecss!=''){usecode+='<link rel="stylesheet" type="text/css" href="'+usecss+'"/>\n';}else{usecode+='<style type="text/css">\n<!-- \n';usecode+='body{background-color: #ffffff;color: #000000;}\n';usecode+='h1{background-color: #ffffff;color: #000066;text-align: center;}\n';usecode+='p{text-align: center;}\n';usecode+='table{border-style: none;margin-left: auto;margin-right: auto;text-align: left;}\n';usecode+='td{vertical-align: top;}\n';usecode+='.justify{text-align: justify;}\n';usecode+='.left{text-align: left;}\n';usecode+=' -->\n</style>\n';}usecode+='</head>\n<body>\n';if(opt==1){usecode+='<form action="<?php if(!isset($_SERVER)){$_SERVER=$HTTP_SERVER_VARS;}echo $_SERVER[\'PHP_SELF\'];?>" method="post" name="Form1">\n<table>\n';usecode+='<tr><td>\n<b>First Name:</b><br />\n<input type="text" size="34" name="First_Name"/>\n</td></tr>\n<tr><td>\n<b>Last Name:</b><br />\n<input type="text" size="34" name="Last_Name"/>\n</td></tr>\n<tr><td>\n<b>Email Address:</b><br />\n<input type="text" size="34" name="Email_Address"/>\n</td></tr>\n<tr><td>\n<b>Subject:</b><br />\n<input type="text" size="34" name="Subject"/>\n</td></tr>\n<tr><td>\n<b>Message:</b><br />\n<textarea name="Message" rows="5" cols="37"></textarea>\n</td></tr>\n<tr><td>\n<input type="checkbox" name="Email_Copy"/>\n<b>Email Copy</b> - Select to receive a copy of the submitted form.\n</td></tr>\n';var curdefreg=document.getElementById('defrequired').value;namval="Email_Address";if(curdefreg!=""){if(curdefreg.charAt(curdefreg.length-1)!=','){curdefreg=curdefreg+",";}}if(curdefreg.indexOf(namval+",")<0){document.getElementById('defrequired').value=curdefreg+namval+",";}}else{var formact="";var usecont="";var addtoNode=document.getElementById('fldtabbod');var fldnum=addtoNode.rows.length;for(var i=7;i<fldnum;i++){var disval=addtoNode.rows[i].cells[0].firstChild.value;var typval=addtoNode.rows[i].cells[1].firstChild.value;var namval=addtoNode.rows[i].cells[2].firstChild.value;var defval=addtoNode.rows[i].cells[3].firstChild.value;var reqval=addtoNode.rows[i].cells[4].firstChild.checked;if(namval==""){var fldname=disval.replace(/ /g,"_");}if(reqval==true){var curdefreg=document.getElementById('defrequired').value;if(curdefreg!=""){if(curdefreg.charAt(curdefreg.length-1)!=','){curdefreg=curdefreg+",";}}if(curdefreg.indexOf(namval+",")<0){document.getElementById('defrequired').value=curdefreg+namval+",";}}addtoNode.rows[i].cells[2].firstChild.value=namval;switch(typval){case 'textarea':
      typfld='<tr><td>\n<b>'+disval+'</b><br />\n<textarea name="'+namval+'">'+defval+'</textarea>\n</td></tr>\n';break;case 'select':
      typfld='<tr><td>\n<b>'+disval+'</b><br />\n<select name="'+namval+'">\n';allopt=defval.split(',');for(var o=0;o<allopt.length;o++){typfld+='<option>'+allopt[o]+'</option>\n';}typfld+='</select>\n</td></tr>\n';break;case 'checkbox':
      if(defval=="checked"){typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'" checked="checked"/>\n</td></tr>\n';}else{typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'"/>\n</td></tr>\n';}break;case 'radio':
      if(defval=="checked"){typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'" checked="checked"/>\n</td></tr>\n';}else{typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'"/><br />\n</td></tr>\n';}break;case 'file':
      typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'" enctype="multipart/form-data"/>\n</td></tr>\n';var formact="multi";if(document.getElementById('deffileatt').value!=namval||document.getElementById('filemaxsize').value==""||document.getElementById('fileallow').value==""){alert("For file attachments to work with this field you must set all file Attachment Options including the Defined File Attachment Form Field to the name of the file field before you Build Form. From the menu go Optional, File Attachments.");}section("sect2");subsection("sub7");window.document.config.deffileatt.focus();break;default:
      typfld='<tr><td>\n<b>'+disval+'</b><br />\n<input type="'+typval+'" name="'+namval+'" value="'+defval+'"/>\n</td></tr>\n';}usecont+=typfld;}if(formact=="multi"){usecode+='<form action="<?php if(!isset($_SERVER)){$_SERVER=$HTTP_SERVER_VARS;}echo $_SERVER[\'PHP_SELF\'];?>" method="post" enctype="multipart/form-data" name="Form1">\n<table>\n';window.document.config.htmldisplay.checked=false;}else{usecode+='<form action="<?php if(!isset($_SERVER)){$_SERVER=$HTTP_SERVER_VARS;}echo $_SERVER[\'PHP_SELF\'];?>" method="post" name="Form1">\n<table>\n';}usecode+=usecont;}usecode+='<tr><td>\n<input type="submit" value="Submit Form"/>\n<input type="reset" value="Reset"/>\n</td></tr>\n</table>\n</form>\n</body>\n</html>';}codebuild2();useBut=document.getElementById("build"+optnum);if(optnum==4){useBut.value="Re-Build Using Form Page Layout Code";}else{useBut.value="Build Form";}useBut.style.color = '#000066';}}function codebuild2(){resetfc();if(regmk==null||!isNaN(regmk)){regmk= Math.floor(604800 + new Date()/1000);var regtext1='- '+regtxtype+' Evaluation version '+regtxtvnum;var regtext2='Registration is required to maintain this software.';}else{var regtext1='- '+regtxtype+' Registered version '+regtxtvnum;var regtext2='You you may not distribute registered software in any form.';}var headcode='<?php\n/*\n\n';headcode+='Software : Form1 '+regtext1+'\nCompany: softSWOT\nWeb Site: www.softswot.com\nCopyright: softSWOT.com\n\n';headcode+='Build: '+regtxtbnum+'\n\n';headcode+='If this message appears in your browser when the file is run from your server, php is not available on that server. Without php Form1 will not function. When php is supported by your server none of this code is displayed or sent to the browser it is fully processed on the server. For more information visit http://www.softswot.com.\n\n';headcode+='Software is provided as is, use is entirely at the users risk, and use acknowledges that softSWOT and all associated parties are held harmless from any claims or losses relating to software provided.\n\n';headcode+=regtext2;headcode+='\n\n\n#### Start User Configuration Settings.\nThe following variables can be user defined by opening this file in a text editor and adjusting the values between each "" or using the Form1 Builder from www.softswot.com to build and modify the web form. For more information visit http://www.softswot.com.\n*/\n\n';headcode+='$delemail = "'+window.document.config.delemail.value+'";\n\n';if(fbtype=='fgsh'){headcode+='$gmuse = "'+window.document.config.gmuse.checked+'";\n';headcode+='$gmusecontenttype = "'+window.document.config.gmusecontenttype.checked+'";\n';headcode+='$gmsendonly = "'+window.document.config.gmsendonly.checked+'";\n';headcode+='$gmemail = "'+window.document.config.gmemail.value+'";\n\n';}if(fbtype=='fmsh'){headcode+='$mysqluse = "'+window.document.config.mysqluse.checked+'";\n';headcode+='$mysqlservername = "'+window.document.config.mysqlservername.value+'";\n';headcode+='$mysqlusername = "'+window.document.config.mysqlusername.value+'";\n';headcode+='$mysqluserpassword = "'+window.document.config.mysqluserpassword.value+'";\n';headcode+='$mysqldatabase = "'+window.document.config.mysqldatabase.value+'";\n';headcode+='$mysqltable = "'+window.document.config.mysqltable.value+'";\n';headcode+='$mysqlemptyvalue = "'+window.document.config.mysqlemptyvalue.value+'";\n';headcode+='$mysqlfieldskip = "'+window.document.config.mysqlfieldskip.value+'";\n';headcode+='$sendonlyiferror = "'+window.document.config.sendonlyiferror.checked+'";\n\n';}headcode+='$showempty = "'+window.document.config.showempty.checked+'";\n';headcode+='$firstupper = "'+window.document.config.firstupper.checked+'";\n';headcode+='$timeoffset = "'+window.document.config.timeoffset.value+'";\n';headcode+='$verifysubject = "'+window.document.config.verifysubject.value+'";\n';headcode+='$verifybody = "'+window.document.config.verifybody.value+'";\n';headcode+='$usehttpvars = "'+window.document.config.usehttpvars.checked+'";\n';headcode+='$usecookvars = "'+window.document.config.usecookvars.checked+'";\n\n';headcode+='$defrequired = "'+window.document.config.defrequired.value+'";\n';headcode+='$asempty = "'+window.document.config.asempty.value+'";\n\n';var ares=window.document.config.autoresponse.value;ares=encodeURIComponent(ares);var lfenc=encodeURIComponent('\\n');var re=/%0D%0A/g;ares=ares.replace(re,lfenc);ares=decodeURIComponent(ares);headcode+='$autoresponse = "'+ares+'";\n\n';headcode+='$htmldisplay = "'+window.document.config.htmldisplay.checked+'";\n';headcode+='$alphasort = "'+window.document.config.alphasort.checked+'";\n';headcode+='$htmlemail = "'+window.document.config.htmlemail.checked+'";\n';headcode+='$breakoff = "'+window.document.config.breakoff.checked+'";\n';headcode+='$jsreturn = "'+window.document.config.jsreturn.checked+'";\n';headcode+='$reasonreturn = "'+window.document.config.reasonreturn.checked+'";\n';headcode+='$setform1url = "'+window.document.config.setform1url.value+'";\n\n';headcode+='$accesspass = "'+window.document.config.accesspass.value+'";\n';headcode+='$cssfile = "'+window.document.config.cssfile.value+'";\n\n';headcode+='$thankurl = "'+window.document.config.thankurl.value+'";\n';headcode+='$requrl = "'+window.document.config.requrl.value+'";\n';headcode+='$ckurl = "'+window.document.config.ckurl.value+'";\n';headcode+='$errurl = "'+window.document.config.errurl.value+'";\n\n';headcode+='$deffirstname = "'+window.document.config.deffirstname.value+'";\n';headcode+='$deflastname = "'+window.document.config.deflastname.value+'";\n';headcode+='$defemail = "'+window.document.config.defemail.value+'";\n';headcode+='$defsubject = "'+window.document.config.defsubject.value+'";\n';headcode+='$defemailcopy = "'+window.document.config.defemailcopy.value+'";\n\n';headcode+='$deffileatt = "'+window.document.config.deffileatt.value+'";\n';headcode+='$filemaxsize = "'+window.document.config.filemaxsize.value+'";\n';headcode+='$fileallow = "'+window.document.config.fileallow.value+'";\n\n';headcode+='$defplus = "'+window.document.config.defplus.value+'";\n';headcode+='$defminus = "'+window.document.config.defminus.value+'";\n';headcode+='$defmultiply = "'+window.document.config.defmultiply.value+'";\n';headcode+='$defdivide = "'+window.document.config.defdivide.value+'";\n';headcode+='$execorder = "'+window.document.config.execorder.value+'";\n';headcode+='$resultname = "'+window.document.config.resultname.value+'";\n\n';headcode+='$csvfile = "'+window.document.config.csvfile.value+'";\n';headcode+='$xmlfile = "'+window.document.config.xmlfile.value+'";\n\n';headcode+='$smtpserver = "'+window.document.config.smtpserver.value+'";\n\n';headcode+='/*\nFixed Process Code Variables\nThese variables can only be set by direct edit in the processing code.\n*/\n';headcode+='$emailbcc = "";\n';headcode+='$emcont = "Content-Type: text/plain;charset=ISO-8859-1";\n\n';headcode+='$rtflink = "";\n\n';headcode+='$excludeval = "";\n';headcode+='$excludemax = "";\n\n';headcode+='/*\n#### End User Configuration Settings.\nOnly adjust the above variable values between each "".\n*/\n\n\n';headcode+='error_reporting(E_ERROR);session_start();header("Cache-control: private");$noDisplays=array();$configvars = array(\'delemail\',\'delemailname\',\'delemaildomain\',\'thankurl\',\'requrl\',\'ckurl\',\'errurl\',\'reasonreturn\',\'jsreturn\',\'setform1url\',\'usehttpvars\',\'usecookvars\',\'breakoff\',\'autoresponse\',\'deffirstname\',\'deflastname\',\'defemail\',\'defsubject\',\'defemailcopy\',\'deffileatt\',\'filemaxsize\',\'fileallow\',\'defrequired\',\'asempty\',\'htmlemail\',\'htmldisplay\',\'alphasort\',\'showempty\',\'timeoffset\',\'verifycode\',\'accesspass\',\'csvfile\',\'xmlfile\',\'cssfile\',\'smtpserver\',\'emailbcc\',\'emcont\',\'mysqluse\',\'mysqlservername\',\'mysqlusername\',\'mysqluserpassword\',\'mysqldatabase\',\'mysqltable\',\'mysqlemptyvalue\',\'mysqlfieldskip\',\'sendonlyiferror\',\'gmuse\',\'gmusecontenttype\',\'gmsendonly\',\'gmemail\');$returnvars=array(\'form_url\',\'form1next\',\'form1_urlf\',\'htmldisnext\',\'accesspassin\',\'accesscode\',\'htmldissend\',\'PHPSESSID\');$noDisplays=array_merge($noDisplays,$configvars,$returnvars);$nopostvars=array(\'emailbcc\',\'emcont\',\'gmemail\');$valdomainsin="'+regdom+'";$regst="'+regmk+'";$domxorcode="'+encdec+'";if(!isset($_POST)){$_POST=$HTTP_POST_VARS;}if(!isset($_SERVER)){$_SERVER=$HTTP_SERVER_VARS;}if(!isset($_COOKIE)){$_COOKIE=$HTTP_COOKIE_VARS;}if(!isset($_FILES)){$_FILES=$HTTP_POST_FILES;}if(!isset($_SESSION)){$_SESSION=$HTTP_SESSION_VARS;}if (strtoupper(substr(PHP_OS, 0, 3) == \'WIN\')){$useeol = "\\r\\n";$usemesseol = $useeol;}elseif (strtoupper(substr(PHP_OS, 0, 3) == \'MAC\')){$useeol = "\\r";$usemesseol = $useeol;}else{$useeol = "\\n";$usemesseol = $useeol;}$usemesseol = $useeol;$htmlheadst=\'<html><head><title>Form Notification</title>\';if($cssfile!=\'\'){$htmlheadst.=\'<link rel="stylesheet" type="text/css" href="\'.$cssfile.\'"/>\';}else{$htmlheadst.=\'<style type="text/css"><!-- \';$htmlheadst.=\'body{background-color: #ffffff;color: #000000;}\';$htmlheadst.=\'h1{background-color: #ffffff;color: #000066;text-align: center;}\';$htmlheadst.=\'p{text-align: center;}\';$htmlheadst.=\'table{border-style: none;margin-left: auto;margin-right: auto;text-align: left;}\';$htmlheadst.=\'td{vertical-align: top;}\';$htmlheadst.=\'a{font-weight: bold;}\';$htmlheadst.=\'.justify{text-align: justify;}\';$htmlheadst.=\'.left{text-align: left;}\';$htmlheadst.=\' --></style>\';}$htmlheadst.=\'</head><body><h1>\';if(!isset($_POST)){$htmldisret=$htmlheadst.\'Form Variables not Valid</h1>\';$htmldisret.=\'<p>Please contact the site owner.<br /><br />The current version of php on this site does not appear to support the required form variables.</p></body></html>\';echo $htmldisret;exit;}foreach($configvars as $Value){if(isset($_POST[$Value])){if (get_magic_quotes_gpc()){$Value=stripslashes($Value);$Value=trim($Value);}else{$Value=trim($Value);}if($delemail==\'\'||$Value!=\'delemail\'){$$Value=$_POST[$Value];}if(isset($nopostvars[$Value])){unset($_POST[$Value]);}}}if($alphasort==\'true\'){ksort($_POST);}$FORM1_PHP=$_SERVER[\'PHP_SELF\'];if(isset($_POST[\'form_url\'])){$FORM1_URL=$_POST[\'form_url\'];$urlparts=parse_url($FORM1_URL);$FORM1_HOST=$urlparts[\'host\'];$FORM1_HOST_SCH=$urlparts[\'scheme\'];}elseif(isset($_SERVER[\'HTTP_REFERER\'])){$FORM1_URL=$_SERVER[\'HTTP_REFERER\'];$urlparts=parse_url($FORM1_URL);$FORM1_HOST=$urlparts[\'host\'];$FORM1_HOST_SCH=$urlparts[\'scheme\'];}if(!isset($FORM1_HOST) || $FORM1_HOST==NULL||$FORM1_HOST==\'\'){$FORM1_HOST=$_SERVER[\'SERVER_NAME\'];}if(!isset($FORM1_URL) || $FORM1_URL==NULL||$FORM1_URL==\'\'){$FORM1_URL=$FORM1_HOST.$FORM1_PHP;}$urlparts=parse_url($FORM1_HOST);$cksch=$urlparts[\'scheme\'];if(empty($cksch)||$cksch==false){if(empty($FORM1_HOST_SCH)||$FORM1_HOST_SCH==false){$FORM1_HOST=\'http://\'.$FORM1_HOST;}else{$FORM1_HOST=$FORM1_HOST_SCH.\'://\'.$FORM1_HOST;}}$FORM1_HOST=strtolower($FORM1_HOST);if(isset($_POST[\'multipage\'])){$mpage=true;if(!isset($_SESSION[\'Form1\'][\'form1_urlf\'])){$_SESSION[\'Form1\'][\'form1_urlf\']=$FORM1_URL;}}else{$mpage=false;}if(isset($_SESSION[\'Form1\'][\'form1_urlf\'])){$form1_urlf=$_SESSION[\'Form1\'][\'form1_urlf\'];}else{$form1_urlf=$FORM1_URL;}$addsession=\'\';if(SID){$FORM1_URL_parts = (explode(\'?\',$FORM1_URL));$FORM1_URL_part=$FORM1_URL_parts[0];$form1_urlf_parts = (explode(\'?\',$form1_urlf));$form1_urlf_part=$form1_urlf_parts[0];$FORM1_PHP_parts = (explode(\'?\',$FORM1_PHP));$FORM1_PHP_part=$FORM1_PHP_parts[0];$addsession=\'?\'.strip_tags(SID);$FORM1_URL_SESS=$FORM1_URL_part.$addsession;$form1_urlf_SESS=$form1_urlf_part.$addsession;$FORM1_PHP_SESS=$FORM1_PHP_part.$addsession;}else{$FORM1_URL_SESS=$FORM1_URL;$form1_urlf_SESS=$form1_urlf;$FORM1_PHP_SESS=$FORM1_PHP;}if($accesspass!=\'\'){if((isset($_SESSION[\'accesspassin\'])&&$_SESSION[\'accesspassin\']== $accesspass)||(isset($_POST[\'accesspassin\'])&&$_POST[\'accesspassin\']==$accesspass)||(isset($_POST[\'accesscode\'])&&$_POST[\'accesscode\']==$accesspass)){if(!isset($_SESSION[\'accesspassin\'])){$_SESSION[\'accesspassin\'] = $accesspass;}}else{$htmldisret=$htmlheadst.\'Access Code Required</h1>\';$htmldisret.=\'<form action="\'.$FORM1_PHP_SESS.\'" method="post"><p><input type="password" name="accesspassin" /><br /><input type="submit" value="Submit Access Code" /><br /><br />\';$htmldisret.=\'Please submit your access code to continue.</p></form></body></html>\';echo $htmldisret;exit;}}if($valdomainsin=="\'+regdom+\'"){$valdom=true;}else{$valdom=false;}$valdomains = (explode(\',\',$valdomainsin));foreach($valdomains as $valdomain){$codeUse = 0;$chAll = \'\';$userNameEsc = $valdomain;$userNameEsc = rawurldecode($userNameEsc);for ($chUsePos=0;$chUsePos < strlen($userNameEsc);$chUsePos++){$chUse = ord($userNameEsc[$chUsePos]);$chEnDe = $chUse^ord($domxorcode[$codeUse]);$chAll .= chr($chEnDe);$codeUse =($codeUse+1)%strlen($domxorcode);}$valdomain=rawurldecode($chAll);$valdomain=strtolower($valdomain);if(strpos($FORM1_HOST,$valdomain)!==false&&strlen($valdomain)>3){$valdom=true;break;}}if(empty($FORM1_HOST)){$valdom=true;}$defrequired=trim($defrequired);$lastcomma=strrchr($defrequired,\',\');if($lastcomma==\',\'){$usestrlen=strlen($defrequired)-1;$defrequired = substr($defrequired,0,$usestrlen);}if($defrequired!=\'\'){$defreqs = (explode(\',\',$defrequired));}else{$defreqs=NULL;}if(!empty($setform1url)){$FORM1_URL=$setform1url;}if($rtflink==\'true\'){$rtfs=\'<p><a href="\'.$FORM1_URL_SESS.\'">Return to Form</a></p>\';$rtfj=\'<p><a href="\'.$FORM1_URL.\'" onclick="history.go(-1);return false;">Return to Form</a></p>\';}else{$rtfs=\'<form action="\'.$FORM1_URL_SESS.\'" method="post"><p><input type="submit" value="Return to Form" name="form1next" /></p></form>\';$rtfj=\'<form action="\'.$FORM1_URL.\'" method="post"><p><input type="submit" onclick="history.go(-1);return false;" value="Return to Form" name="form1next" /></p></form>\';}if($rtflink==\'true\'){$rtfss=\'<p><a href="\'.$FORM1_URL_SESS.\'">Return to Form</a></p>\';$rtfsj=\'<p><a href="\'.$FORM1_URL.\'">Return to Form</a></p>\';}else{$rtfss=\'<form action="\'.$FORM1_URL_SESS.\'" method="post"><p><input type="submit" value="Return to Form" /></p></form>\';$rtfsj=\'<form action="\'.$FORM1_URL.\'" method="post"><p><input type="submit" value="Return to Form" /></p></form>\';}$CntPost=count($_POST);if($CntPost>0 && !isset($_POST[\'form1next\']) &&!isset($_POST[\'htmldisnext\'])&&!isset($_POST[\'accesspassin\'])){$form1_urlf_parts = (explode(\'?\',$form1_urlf));$form1_urlf=$form1_urlf_parts[0];if($resultname!=\'\'){$oporders=NULL;$oppluss=NULL;$opminuss=NULL;$opmultiplys=NULL;$opdivides=NULL;$execorder=trim($execorder);if($execorder!=\'\'){$oporders = (explode(\',\',$execorder));}$defplus=trim($defplus);if($defplus!=\'\'){$oppluss = (explode(\',\',$defplus));}$defminus=trim($defminus);if($defminus!=\'\'){$opminuss = (explode(\',\',$defminus));}$defmultiply=trim($defmultiply);if($defmultiply!=\'\'){$opmultiplys = (explode(\',\',$defmultiply));}$defdivide=trim($defdivide);if($defdivide!=\'\'){$opdivides = (explode(\',\',$defdivide));}$runresult=0;if(is_array($oporders)){foreach($oporders as $oporder){if(isset($_POST[$oporder])){$opval=$_POST[$oporder];if(is_numeric($opval)){if (is_array($oppluss)&&in_array($oporder, $oppluss)){$runresult=$runresult+$opval;}elseif (is_array($opminuss)&&in_array($oporder, $opminuss)){$runresult=$runresult-$opval;}elseif (is_array($opmultiplys)&&in_array($oporder, $opmultiplys)){$runresult=$runresult*$opval;}elseif (is_array($opdivides)&&in_array($oporder, $opdivides)){$runresult=$runresult/$opval;}}}}}$tempArray = array($resultname => $runresult);$_POST = array_merge ($_POST, $tempArray);}if(isset($_SESSION[\'Form1\'])){$prepost=$_SESSION[\'Form1\'];$_POST = array_merge($prepost,$_POST);}if(isset($_POST[\'multipage\'])){unset($_POST[\'multipage\']);}$_SESSION[\'Form1\'] = $_POST;$delemail =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$delemail);if($delemail==\'\'&&isset($delemailname)&&isset($delemaildomain)){$delemail=$delemailname.\'@\'.$delemaildomain;}$delemails = (explode(\',\',$delemail));if(is_array($delemails)){foreach($delemails as $delemaileach){$delemaileach=trim($delemaileach);if (!ereg(\'^[-!#$%&\\\'*+\\\\./0-9=?A-Z^_`a-z{|}~]+\'.\'@\'.\'[-!#$%&\\\'*+\\\\/0-9=?A-Z^_`a-z{|}~]+\\.\'.\'[-!#$%&\\\'*+\\\\./0-9=?A-Z^_`a-z{|};~]+$\',$delemaileach)){$htmldisret=$htmlheadst.\'Delivery Email Address Not Valid</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>Please contact the site owner.<br /><br />The Delivery Email Address <b>\'.$delemaileach.\'</b> does not appear to be valid.<br /><br />Please provide only valid delivery email addresses in the configuration variable or field.</p></body></html>\';echo $htmldisret;exit;}}$delemail1=trim($delemails[0]);$delemail1 =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$delemail1);}else{$htmldisret=$htmlheadst.\'Delivery Email Address Missing</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>Please contact the site owner.<br /><br />A Delivery Email Address appears to be missing.<br /><br />Please provide at least one delivery email address in the configuration variable or field.</p></body></html>\';echo $htmldisret;exit;}$filealls = (explode(\',\',$fileallow));if($breakoff==\'true\'){$breaktype=\' \';}else{$breaktype=$usemesseol;}$formin=NULL;$formcsv=NULL;$formmulti=NULL;$formmultihtml=NULL;$htmldata=NULL;$csvdata=NULL;$xmldata=NULL;$filedata=NULL;$reqck=NULL;$emailcc=NULL;$subjectin=\'Form Submission\';$emailin=NULL;$firstnamein=NULL;$lastnamein=NULL;$dbdatas=NULL;if(!isset($mysqluse)){$mysqluse=\'false\';}if(!isset($gmuse)){$gmuse=\'false\';}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas=array();}if($smtpserver!=\'\'){ini_set(\'SMTP\', $smtpserver);ini_set(\'sendmail_from\', $delemail1);}$excludecnt=0;foreach($_POST as $Name=>$Value){$Name=trim($Name);if(!empty($excludeval)&&!empty($excludemax)){if(strpos($Value,$excludeval)!==false){$excludecnt++;}if($excludecnt>$excludemax){exit();}}if(is_array($Value)){foreach($Value as $formName=>$formValue){if (get_magic_quotes_gpc()){$formValue=stripslashes($formValue);$formValue=trim($formValue);}else{$formValue=trim($formValue);}$formmulti .="$formValue, ";}$Value=$formmulti;}else{if (get_magic_quotes_gpc()){$Value=stripslashes($Value);$Value=trim($Value);}else{$Value=trim($Value);}}if($Name==trim($defemailcopy)){$emailcc=$Value;}if(is_array($defreqs)){$defreqsnum=0;foreach($defreqs as $defreq){if($defreq!=""&&$Name==trim($defreq)){if($Value===NULL || $Value==\'\'){$reqck=\'fail\';}else{$defemps = (explode(\',\',$asempty));if(is_array($defemps)){foreach($defemps as $defemp){if($defemp!=""&&$Value==trim($defemp)){$reqck=\'fail\';break;}}}}unset($defreqs[$defreqsnum]);$defreqs=array_values($defreqs);break;}$defreqsnum++;}}if(isset($reqck)&&$reqck==\'fail\'){$Name = ereg_replace (\'_\', \' \', $Name);$reqck==\'reset\';if(!$requrl){$htmldisret=$htmlheadst.\'Required Field Input Missing</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>Please use the Return to Form above to return to the form and complete the required field <b>\'.$Name.\'</b>.</p></body></html>\';echo $htmldisret;}else{if($reasonreturn==\'true\'){$Name=urlencode($Name);header("Location: $requrl?reason=$Name");}else{header("Location: $requrl");}}exit;}if($Name==trim($defemail)){if($Value!=\'\'){$Value =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$Value);$emailin=$Value;}}if($Name==trim($defsubject)&&$Value){$Value =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$Value);$subjectin=$Value;}if($Name==trim($deffirstname)){$Value =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$Value);$firstnamein=$Value;}if($Name==trim($deflastname)){$Value =preg_replace("/(\\r\\n|\\n|\\r|\\x0A|\\x0D|\\x0D\\x0A)/i",\'\',$Value);$lastnamein=$Value;}}if(is_array($defreqs)&& count($defreqs)>0){$defreq=$defreqs[0];$defreq = ereg_replace (\'_\', \' \', $defreq);if(!$requrl){$htmldisret=$htmlheadst.\'Required Field Input Missing</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>Please use the Return to Form above to return to the form and complete the required field <b>\'.$defreq.\'</b>.</p></body></html>\';echo $htmldisret;}else{if($reasonreturn==\'true\'){$Name=urlencode($Name);header("Location: $requrl?reason=$defreq");}else{header("Location: $requrl");}}exit;}if(!isset($emailin)||$emailin==\'\'){$emailin=$delemail1;}if ($emailin!=$delemail1&&!ereg(\'^[-!#$%&\\\'*+\\\\./0-9=?A-Z^_`a-z{|}~]+\'.\'@\'.\'[-!#$%&\\\'*+\\\\/0-9=?A-Z^_`a-z{|}~]+\\.\'.\'[-!#$%&\\\'*+\\\\./0-9=?A-Z^_`a-z{|};~]+$\',$emailin)){if(!$ckurl){$htmldisret=$htmlheadst.\'Email Address Not Valid</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>The Email Address <b>\'.$emailin.\'</b> does not appear to be valid.<br /><br />Please use the Return to Form above to return to the form and provide a valid email address.</p></body></html>\';echo $htmldisret;}else{if($reasonreturn==\'true\'){header("Location: $ckurl?reason=$emailin");}else{header("Location: $ckurl");}}exit();}else{if(!isset($emailin)||$emailin==\'\'){$emailin=$delemail1;}if(!$firstnamein&&!$lastnamein){$from_email=$emailin;}elseif(!$lastnamein){$firstnameine = ereg_replace (\',\', \' \', $firstnamein);$from_email="$firstnameine<$emailin>";}elseif(!$firstnamein){$lastnameine = ereg_replace (\',\', \' \', $lastnamein);$from_email="$lastnameine<$emailin>";}else{$firstnameine = ereg_replace (\',\', \' \', $firstnamein);$lastnameine = ereg_replace (\',\', \' \', $lastnamein);$from_email="$firstnameine $lastnameine<$emailin>";}if($smtpserver!=\'\'){$from_email=$delemail1;}foreach($_POST as $Name=>$Value){$Name=trim($Name);if(!in_array($Name,$noDisplays)&&(ucfirst($Name)==$Name||$firstupper!=\'true\'||($gmuse==\'true\'&&(ereg(\'^cs[0-9]_*\',$Name))))){$NameXML = $Name;$Name = ereg_replace (\'_\', \' \', $Name);$NameHTML=htmlentities($Name);$NameHTML=nl2br($NameHTML);$formmulti =\'\';if(is_array($Value)){$formin .="$Name: $breaktype";foreach($Value as $formName=>$formValue){if (get_magic_quotes_gpc()){$formValue=stripslashes($formValue);$formValue=trim($formValue);}else{$formValue=trim($formValue);}$formmulti .="$formValue, ";}$formin .="$formmulti".$usemesseol.$usemesseol;if($htmlemail==\'true\'||$htmldisplay==\'true\'){$formmultiHTML=htmlentities($formmulti);$formmultiHTML=nl2br($formmultiHTML);$htmldata.="<tr><td><b>$NameHTML</b></td><td>$formmultiHTML</td></tr>";}if($csvfile!=\'\'){$csvdata.="\\"$formmulti\\",";}if($xmlfile!=\'\'){$xmldata.="<$NameXML>$formmulti</$NameXML>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[$NameXML]=$formmulti;}}else{if (get_magic_quotes_gpc()){$Value=stripslashes($Value);$Value=trim($Value);}else{$Value=trim($Value);}if($showempty==\'true\'||$Value!=NULL){$formin .=$Name.":".$breaktype.$Value.$usemesseol.$usemesseol;if($htmlemail==\'true\'||$htmldisplay==\'true\'){$ValueHTML=htmlentities($Value);$ValueHTML=nl2br($ValueHTML);$htmldata.="<tr><td><b>$NameHTML</b></td><td>$ValueHTML</td></tr>";}}if($csvfile!=\'\'){$csvdata.="\\"$Value\\",";}if($xmlfile!=\'\'){$xmldata.="<$NameXML>$Value</$NameXML>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[$NameXML]=$Value;}}}}if(is_numeric($timeoffset)&&$timeoffset!=0){$timepro=gmdate("D, d M Y H:i:s",time()+3600*$timeoffset)." Local";$timedb=gmdate("Y-m-d H:i:s",time()+3600*$timeoffset);}else{$timepro=gmdate("D, d M Y H:i:s",time())." GMT/UTC";$timedb=gmdate("Y-m-d H:i:s",time());}$htmldisdat=$htmldata;if($htmlemail==\'true\'){$htmldata.="<tr><td>Processed</td><td>$timepro</td></tr>";}if($xmlfile!=\'\'){$xmldata.="<Processed>$timepro</Processed>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[\'Processed\']=$timedb;}$formin .="Processed: $timepro".$usemesseol.$usemesseol;if($csvfile!=\'\'){$csvdata.="\\"$timepro\\",";}if($usehttpvars=="true"&&$_SERVER){$httpvars=array("HTTP_USER_AGENT"=>"User Browser","REMOTE_ADDR"=>"User IP Address","SERVER_ADDR"=>"Form1 PHP Server IP","SERVER_NAME"=>"Form1 PHP Server Name");$formin .="Variables -".$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td colspan=\'2\'>__________</td></tr><tr><td colspan=\'2\'><b>Variables</b></td></tr>";}if($xmlfile!=\'\'){$xmldata.="<Variables>";}foreach($httpvars as $httpvar=>$httpdesc){$formin .="$httpdesc ($httpvar): $_SERVER[$httpvar] ".$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td align=\'right\'><b>$httpdesc ($httpvar)</b></td><td>$_SERVER[$httpvar] </td></tr>";}if($csvfile!=\'\'){$csvdata.="\\"$_SERVER[$httpvar]\\",";}if($xmlfile!=\'\'){$xmldata.="<$httpvar>$_SERVER[$httpvar]</$httpvar>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[$httpvar]=$_SERVER[$httpvar];}}$formin .="Form1 PHP Script (PHP_SELF): $FORM1_PHP ".$usemesseol."Form1 URL Domain: $FORM1_HOST ".$usemesseol."Form1 URL (HTTP_REFERER): $form1_urlf ".$usemesseol.$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td align=\'right\'><b>Form1 PHP Script (PHP_SELF)</b></td><td>$FORM1_PHP</td></tr>";$htmldata.="<tr><td align=\'right\'><b>Form1 URL Domain</b></td><td>$FORM1_HOST</td></tr>";$htmldata.="<tr><td align=\'right\'><b>Form1 URL (HTTP_REFERER)</b></td><td>$form1_urlf</td></tr>";}if($csvfile!=\'\'){$csvdata.="\\"$FORM1_PHP\\",\\"$FORM1_HOST\\",\\"$form1_urlf\\",";}if($xmlfile!=\'\'){$xmldata.="<PHP_SELF>$FORM1_PHP</PHP_SELF><Domain>$FORM1_HOST</Domain><HTTP_REFERER>$form1_urlf</HTTP_REFERER>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[\'PHP_SELF\']=$FORM1_PHP;$dbdatas[\'Domain\']=$FORM1_HOST;$dbdatas[\'HTTP_REFERER\']=$form1_urlf;}$formin .=$usemesseol;if($xmlfile!=\'\'){$xmldata.="</Variables>";}}if($usecookvars=="true"&&$_COOKIE){$formin .="Cookies -".$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td colspan=\'2\'>__________</td></tr><tr><td colspan=\'2\'><b>Cookies</b></td></tr>";}if($xmlfile!=\'\'){$xmldata.="<Cookies>";}foreach($_COOKIE as $Name=>$Value){if (get_magic_quotes_gpc()){$Value=stripslashes($Value);$Value=trim($Value);}else{$Value=trim($Value);}$Value=urlencode($Value);$formin .="$Name: $Value".$usemesseol;if($htmlemail==\'true\'){$ValueHTML=htmlentities($Value);$htmldata.="<tr><td align=\'right\'><b>$Name</b></td><td>$ValueHTML</td></tr>";}if($csvfile!=\'\'){$csvdata.="\\"$Value\\",";}if($xmlfile!=\'\'){$xmldata.="<$Name>$Value</$Name>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[$Name]=$Value;}}if($xmlfile!=\'\'){$xmldata.="</Cookies>";}}$from_email=trim(stripslashes($from_email));$formin=trim(stripslashes($formin));$subjectin=trim(stripslashes($subjectin));$curs=time();if(is_numeric($regst)){if($regst<$curs){header("Location: http://www.softswot.com/FormBuildExp.php?FORM1_HOST=$FORM1_HOST&FORM1_URL=$FORM1_URL");exit();}else{$evalr = round(($regst - $curs)/(24*60*60), 2);$formin .=$usemesseol.$usemesseol.$usemesseol."powered by Form1 software, available free for evaluation from www.softswot.com.";$formin .=$usemesseol."Evaluation Only. Evaluation period expires in $evalr days.".$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td colspan=\'2\'><b>powered by Form1 software, available free for evaluation from www.softswot.com.</b></td></tr>";$htmldata.="<tr><td colspan=\'2\'><b>Evaluation Only. Evaluation period expires in $evalr days.</b></td></tr>";}}}elseif($valdom!=true){$headredir="http://www.softswot.com/FormBuildDom.php?FORM1_HOST=$FORM1_HOST&FORM1_URL=$FORM1_URL";header("Location: $headredir");exit();}if($verifybody!=\'\'){$formin .=$usemesseol.$usemesseol."Verification Code: $verifybody".$usemesseol;if($htmlemail==\'true\'){$htmldata.="<tr><td colspan=\'2\'>__________</td></tr><tr><td>Verification Code</td><td>$verifybody</td></tr>";}if($mysqluse==\'true\'||$gmuse==\'true\'){$dbdatas[\'Verification\']=$verifybody;}}if($htmldisplay==\'true\'&&!isset($_POST[\'htmldissend\'])){$htmldisdat=$htmlheadst.$subjectin.\'</h1><p><table>\'.$htmldisdat;if($jsreturn==\'true\'){$htmldisdat.=\'<tr><td><form action="\'.$FORM1_URL.\'" method="post"><p class="left">\';$htmldisdat.=\'<input type="submit" value="Return to Form" onclick="history.go(-1);return false;" name="form1next" />\';$htmldisdat.=\'</p></form></td><td>\';}else{$htmldisdat.=\'<tr><td><form action="\'.$FORM1_URL_SESS.\'" method="post"><p class="left">\';$htmldisdat.=\'<input type="submit" value="Return to Form" name="form1next" />\';$htmldisdat.=\'</p></form></td><td>\';}$htmldisdat.=\'<form action="\'.$FORM1_PHP_SESS.\'" method="post"><p class="left">\';foreach($_POST as $Name=>$Value){if(is_array($Value)){$formmultihtml =\'\';foreach($Value as $formName=>$formValue){$formValue=trim($formValue);$formmultihtml .="$formValue, ";}$Value=$formmultihtml;}else{$Value=trim($Value);}$NameHTML=htmlentities($Name);$ValueHTML=htmlentities($Value);$htmldisdat.=\'<input type="hidden" name="\'.$NameHTML.\'" value="\'.$ValueHTML.\'" />\';}$FORM1_URLHTML=htmlentities($FORM1_URL);$htmldisdat.=\'<input type="hidden" name="form_url" value="\'.$FORM1_URLHTML.\'" />\';if($mpage==true){$htmldisdat.=\'<input type="submit" value="Next" name="htmldisnext" /></p></form></td></tr>\';}else{$htmldisdat.=\'<input type="submit" value="Send Form" name="htmldissend" /></p></form></td></tr>\';}$htmldisdat.=\'</table></p>\';$htmldisdat.=\'</body></html>\';echo $htmldisdat;exit;}if($mpage!=true){if($htmlemail==\'true\'){$htmldata=\'<html><body><p><table cellpadding="5">\'.$htmldata;$htmldata.=\'</table></p></body></html>\';}if($xmlfile!=\'\'){$xmldata=\'<?xml version="1.0" ?><Form1_XML>\'.$xmldata;$xmldata.=\'</Form1_XML>\';}$mysqlfail=false;if($mysqluse==\'true\'){$MYSQLName=\'\';$MYSQLValue=\'\';$mysqlfieldnames = array();$skipfields = (explode(\',\',$mysqlfieldskip));$connection = @mysql_connect($mysqlservername,$mysqlusername,$mysqluserpassword);if(@mysql_select_db($mysqldatabase,$connection)){$sql = "SHOW COLUMNS FROM $mysqltable";$result = @mysql_query($sql);while ($row = @mysql_fetch_array($result)){$testfieldname=$row["Field"];$testfieldname=trim($testfieldname);$skipck=\'use\';if(is_array($skipfields)){foreach($skipfields as $skipfield){if($skipfield!=""&&$testfieldname==trim($skipfield)){$skipck=\'skip\';break;}}}if($skipck!=\'skip\'){$mysqlfieldnames[] = $testfieldname;}}foreach($mysqlfieldnames as $mysqlfieldname){if(isset($dbdatas[$mysqlfieldname])){$Value=$dbdatas[$mysqlfieldname];if(get_magic_quotes_gpc()){$Value= stripslashes($Value);}$Value=mysql_real_escape_string($Value);$Value=trim($Value);if($Value==\'\'){$Value=$mysqlemptyvalue;}}else{$Value=$mysqlemptyvalue;}$MYSQLName.="$mysqlfieldname, ";$MYSQLValue.="\'$Value\', ";}$MYSQLName = rtrim($MYSQLName, ", ");$MYSQLValue = rtrim($MYSQLValue, ", ");$sql = "INSERT INTO $mysqltable ($MYSQLName) VALUES ($MYSQLValue)";$result =@mysql_query($sql);if(!$result){$mysqlfail=true;}@mysql_close($connection);}else{$mysqlfail=true;}}$arxheaders = $emcont.$useeol;if($htmlemail==\'true\'||$xmlfile!=\'\' ||$csvfile!=\'\' || ($deffileatt!=\'\' && isset($_FILES[$deffileatt]) && is_file($_FILES[$deffileatt][\'tmp_name\']))){if(($deffileatt!=\'\' && isset($_FILES[$deffileatt]) && is_file($_FILES[$deffileatt][\'tmp_name\']))){set_magic_quotes_runtime(0);$fileatt = $_FILES[$deffileatt][\'tmp_name\'];$fileatttype = $_FILES[$deffileatt][\'type\'];$fileattname = $_FILES[$deffileatt][\'name\'];if(filesize($fileatt)>$filemaxsize){$htmldisret=$htmlheadst.\'Maximum File Size Exceeded</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>The maximum allowable upload file size is \'.$filemaxsize.\' bytes.<br /><br />The size of \'.$fileattname.\' is \'.filesize($fileatt).\' bytes.<br /><br />Please use the Return to Form above to return to the form and submit a smaller file.</p></body></html>\';echo $htmldisret;exit;}else{$typeok=false;if(is_array($filealls)){foreach($filealls as $fileall){if($fileall==$fileatttype){$typeok=true;break;}}}if($typeok==false){$htmldisret=$htmlheadst.\'File Type Not Allowed</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>The file type of your upload file is <b>\'.$fileatttype.\'</b>.<br /><br />This file type is not allowed for upload.<br /><br />Please use the Return to Form above to return to the form and submit a different file type.</p></body></html>\';echo $htmldisret;exit;}else{if (is_uploaded_file($fileatt)){$file = fopen($fileatt,\'rb\');$filedata = fread($file,filesize($fileatt));fclose($file);}else{$htmldisret=$htmlheadst.\'File Upload Error</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfj;}else{$htmldisret.=$rtfs;}$htmldisret.=\'<p>The file upload failed.<br /><br />Please use the Return to Form above to return to the form and resubmit.</p></body></html>\';echo $htmldisret;exit;}}}}$semi_rand = md5(time());$mime_boundary = "==Multipart_Boundary_$semi_rand==";$xheaders = "MIME-Version: 1.0".$useeol."Content-Type: multipart/mixed;boundary=\\"".$mime_boundary."\\"".$useeol;$message = "This is a multi-part message in MIME format.".$useeol;$mimelast="";if(isset($htmldata)){$mimelast="html";}if(isset($filedata)){$mimelast="attach";}if(isset($csvdata)){$mimelast="csv";}if(isset($xmldata)){$mimelast="xml";}if(isset($htmldata)){$message.= $useeol."--".$mime_boundary.$useeol;$message.="Content-Type: text/html".$useeol;$message.="Content-Transfer-Encoding: 7bit".$useeol;$message.=$useeol.$htmldata.$useeol;if($mimelast=="html"){$message.=$useeol."--".$mime_boundary."--".$useeol;}}else{$message.=$useeol."--".$mime_boundary.$useeol;$message.="Content-Type: text/plain".$useeol;$message.="Content-Transfer-Encoding: 7bit".$useeol;$message.=$useeol.$formin.$useeol;}if(isset($filedata)){$filedata = chunk_split(base64_encode($filedata));$message.= $useeol."--".$mime_boundary.$useeol;$message.="Content-Type: $fileatttype;name=\\"$fileattname\\"".$useeol;$message.="Content-Disposition: attachment;filename=\\"$fileattname\\"".$useeol;$message.="Content-Transfer-Encoding: base64".$useeol;$message.=$useeol.$filedata.$useeol;if($mimelast=="attach"){$message.=$useeol."--".$mime_boundary."--".$useeol;}}if(isset($csvdata)){$csvdata = chunk_split(base64_encode($csvdata));$message.= $useeol."--".$mime_boundary.$useeol;$message.="Content-Type: text/csv;name=\\"$csvfile\\"".$useeol;$message.="Content-Disposition: attachment;filename=\\"$csvfile\\"".$useeol;$message.="Content-Transfer-Encoding: base64".$useeol;$message.=$useeol.$csvdata.$useeol;if($mimelast=="csv"){$message.=$useeol."--".$mime_boundary."--".$useeol;}}if(isset($xmldata)){$xmldata = chunk_split(base64_encode($xmldata));$message.= $useeol."--".$mime_boundary.$useeol;$message.="Content-Type: text/xml;name=\\"$xmlfile\\"".$useeol;$message.="Content-Disposition: attachment;filename=\\"$xmlfile\\"".$useeol;$message.="Content-Transfer-Encoding: base64".$useeol;$message.= $useeol.$xmldata.$useeol;if($mimelast=="xml"){$message.=$useeol."--".$mime_boundary."--".$useeol;}}$formin=$message;}else{$xheaders = $arxheaders;}$xheaders .="From: $from_email".$useeol;if(!empty($emailcc)){$xheaders.="CC: $emailin".$useeol;}if(!empty($emailbcc)){$xheaders.="BCC: $emailbcc".$useeol;}$xheaders.="Reply-To: $from_email".$useeol."Return-path: $emailin".$useeol."X-Mailer: PHP/" . phpversion();if($verifysubject!=\'\'){$subjectin .= " $verifysubject";}$gmfail=false;if($gmuse==\'true\'){if($gmemail==\'\'){$gmemail=$delemail;}$gmsubject=$subjectin;if($gmusecontenttype=="true"){$gmheaders ="Content-Type: application/x-gm-impdata".$useeol;$gmto = "<$gmemail>";}else{$gmheaders =$emcont.$useeol;$gmto = "\\"{\\$GM-WEBIMPORT\\$}\\"<$gmemail>";}$gmheaders.="From: $gmemail".$useeol;$gmheaders.="Reply-To: $gmemail".$useeol."Return-path: $gmemail".$useeol."X-Mailer: PHP/" . phpversion();$gmform = "[Instructions]".$usemesseol."SaveThis=Web Import File".$usemesseol;$gmformcs= $usemesseol."[ContSupp]".$usemesseol;$dataMk=false;$dataSt=false;$dataCS=false;foreach($dbdatas as $Name=>$Value){if(ereg(\'DataStart\',$Name)){$dataMk=true;}if(ereg(\'^cs[0-9]_*\',$Name)){$dataCS=true;}}if ($dataMk==false){$gmform=$gmform.$usemesseol."[Data]".$usemesseol;}foreach($dbdatas as $Name=>$Value){if($dataMk==true && $dataSt==false){if(ereg(\'DataStart\',$Name)){$dataSt=true;$gmform = $gmform.$usemesseol."[Data]".$usemesseol;}else{if(ereg(\'^cs[0-9]_*\',$Name)){$gmformcs .= $Name.\'=\'.$Value.$usemesseol;}else{$gmform.=$Name.\'=\'.$Value.$usemesseol;}}}else{if (ereg(\'^cs[0-9]_*\',$Name)){$gmformcs.=$Name.\'=\'.$Value.$usemesseol;}else{$gmform.=$Name.\'=\'.$Value.$usemesseol;}}}if($dataCS==true){$gmform.=$formcs;}if(!@mail($gmto,$gmsubject,$gmform,$gmheaders)){$gmfail=true;}}if(($gmuse!=\'true\'&&$mysqluse!=\'true\')||(isset($sendonlyiferror)&&$sendonlyiferror!=\'true\')||$mysqlfail==true||(isset($gmsendonly)&&$gmsendonly!=\'true\')||$gmfail==true){if($mysqlfail==true){$subjectin=\'Error MYSQL \'.$subjectin;}if($gmfail==true){$subjectin=\'Error GoldMine \'.$subjectin;}$mailok=@mail($delemail,$subjectin,$formin,$xheaders);}else{$mailok=true;}if($mailok){if(isset($autoresponse)){$autoresponse=trim(stripslashes($autoresponse));if($autoresponse!=""){$arxheaders .="From: $delemail1".$useeol."Reply-To: $delemail1".$useeol."Return-path: $delemail1".$useeol."X-Mailer: PHP/" . phpversion();@mail($emailin,$subjectin,$autoresponse,$arxheaders);}}if(!$thankurl){$htmldisret=$htmlheadst.\'Thank You - Form Delivered</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfsj;}else{if($rtflink==\'true\'){$htmldisret.=\'<p><a href="\'.$form1_urlf.\'">Return to Form</a></p></form>\';}else{$htmldisret.=\'<form action="\'.$form1_urlf.\'" method="post"><p><input type="submit" value="Return to Form" name="form1next" /></p></form>\';}}$htmldisret.=\'<p>Your form has been delivered.</p></body></html>\';echo $htmldisret;}else{if($reasonreturn==\'true\'){header("Location: $thankurl?reason=$form1_urlf");}else{header("Location: $thankurl");}}session_unset();session_destroy();exit();}else{if(!$errurl){$htmldisret=$htmlheadst.\'Form Delivery Error</h1>\';if($jsreturn==\'true\'){$htmldisret.=$rtfsj;}else{$htmldisret.=$rtfss;}$htmldisret.=\'<p>Your form has not been delivered.<br /><br />Please use the Return to Form above to return to the form and resubmit.</p></body></html>\';echo $htmldisret;}else{header("Location: $errurl");}exit();}}}}';headcode+='\n\n/*\n#### Below here is standard html.\nYou can adjust the html as required. You can also copy the code from here up (including the \?\> following this comment) and paste it at the top (above the html tag and any document type tags) of any html form page. All forms must be valid html and follow the guidelines provided in the help file.\n*/?>\n\n\n';document.getElementById('sect6').style.display='block';window.document.config.formcode.value=headcode+usecode;window.document.config.procode.value=headcode;window.document.config.pagecode.value=usecode;window.document.config.formcode.select();section('sect6');window.document.config.formcode.focus();}function addfields(){var addfld=document.getElementById('addnum').value;var addtoNode=document.getElementById('fldtabbod');var fldrowNode=addtoNode.rows[5];fldrowNode.style.display='block';for(var i=0;i<addfld;i++){var newtrNode = document.createElement('tr');var alltdNode=fldrowNode.childNodes;for(var n=0;n<alltdNode.length;n++){var newtdNode=alltdNode[n].cloneNode(true);newtrNode.appendChild(newtdNode);}addtoNode.appendChild(newtrNode);}fldrowNode.style.display='none';}function adddef(row){switch(row){case '0':
   document.getElementById('dffirstname').value=document.getElementById('deffirstname').value;break;case '1':
   document.getElementById('dflastname').value=document.getElementById('deflastname').value;break;case '2':
   document.getElementById('dfemail').value=document.getElementById('defemail').value;break;case '3':
   document.getElementById('dfsubject').value=document.getElementById('defsubject').value;break;case '4':
   document.getElementById('dfemailcc').value=document.getElementById('defemailcopy').value;break;default:}var addtoNode=document.getElementById('fldtabbod');var fldrowNode=addtoNode.rows[row];fldrowNode.style.display='block';var newtrNode = document.createElement('tr');var alltdNode=fldrowNode.childNodes;for(var n=0;n<alltdNode.length;n++){var newtdNode=alltdNode[n].cloneNode(true);newtrNode.appendChild(newtdNode);}addtoNode.appendChild(newtrNode);fldrowNode.style.display='none';}function formview(vopt){useBut=window.document.getElementById("viewform"+vopt);useBut.value="Loading.................";useBut.style.color = '#ff0000';var pagecode=window.document.config.pagecode.value
if(pagecode!=''){usewin=window.open(window.location.href,"usewin",winpara);usewin.document.open("text/html");usewin.document.write(pagecode);usewin.document.close();usewin.status = "Form Layout for the Page Code.";}else{alert("You must have Form Page Layout Code (generated when you Build Form) before you can View Form Layout.");}useBut=document.getElementById("viewform"+vopt);useBut.value="View Form Layout";useBut.style.color = '#000066';usewin.focus();}function remfields(){addfld=document.getElementById('addnum').value;addtoNode=document.getElementById('fldtabbod');fldrowNum=addtoNode.rows.length;defrowNum=7;allremNum=fldrowNum-defrowNum;if(allremNum>=addfld){for(var i=0;i<addfld;i++){addtoNode.removeChild(addtoNode.lastChild);}}else{alert("You cannot remove "+addfld+" rows.");}}function resetar(){window.document.config.autoresponse.value ="";}function resetfc(resetta){if(resetta==''){window.document.config.formcode.value ="";window.document.config.procode.value ="";window.document.config.pagecode.value ="";}else if(resetta=='formcode'){window.document.config.formcode.value ="";}else if(resetta=='procode'){window.document.config.procode.value ="";}else if(resetta=='pagecode'){window.document.config.pagecode.value ="";}window.focus();}function selall(selta){if(selta=='formcode'){if(window.document.config.formcode.value=="reset"){var cookName = encodeURIComponent(softSWOTMk+"Config");var expDate = new Date();expDate.setTime(expDate.getTime() - 1000);document.cookie = cookName + "= " + ";expires=" + expDate.toUTCString();alert("Registration details reset.");window.location.reload();return;}window.document.config.formcode.select();}else if(selta=='procode'){window.document.config.procode.select();}else if(selta=='pagecode'){window.document.config.pagecode.select();}window.focus();}function comm(sectnum){if (document.getElementById){fbtype='fgsh';regtxtvnum='30';regtxtbnum='20061004';if(fbtype=='fgsh'){encdec = 'pbBLcwVKP6';regtxtype='Form1 Builder GoldMine';var title = "6%0D0!RRd%7B%12C%19%0E%26)%11Rd%7B%17Y%1C%06%0F%25%0D%12sy%60e%1F%046%3B%02%053";var regAm = "%251g~WBoe%60%06";var regDisplay = "%18%166%3CFD%17nbpUP%04%3B%14%00x8%3FP%04%115%23%17Y5%24%3D%13B%24%04%23%11%1A%11%24%3CR%3D%0B%2C)1%121e%20%5E%00";var regURL = "%18%166%3CFD%17nbpUP%04%3B%14%00x8%3FP%04%115%23%17Y5%24%3D%13B%24%04%23%11%1A%11%24%3CR%3D%0B%2C)1%121e%20%5E%00";var siteName = "%03%0D%2480%20%19%1F";var siteWWW = "%07%155b%10%180%3F%23A%1F%16l%2F%0C%1A";var siteURL = "%18%166%3CFD%17nbpUP%04%3B%14%00x8%3FP%04%115%23%17Y5%24%3D";var upURL = "%18%166%3CFD%17nbpUP%04%3B%14%00x8%3FP%04%115%23%17Y5%24%3D%13B%247%3C%04%057%2F5%18%00%0A2";var copyYear = "";var evalTo = "G";var expTo = "AV";softSWOTMk = 'softSWOTfgsh';cookNameUse = "softswotfgshVars";}else if(fbtype=='fmsh'){encdec = 'TL3fumawJg';regtxtype='Form1 Builder MYSQL';var title = "%12%23A%0BDHSG%08%12%3D%20W%03%07HSG%07%3E%07%1D%7FCG%5D2%18%2C%13%23-A%03";var regAm = "%01%1F%16TAXXYzW";var regDisplay = "%3C8G%16P%5E%20Rx!q~u%11%02%1AO%04%25%01%20%3FD%09%01C%02%18'Bf%0Au%09%07%00%2C.%196%18%1EV%01%5B%1D%09%07";var regURL = "%3C8G%16P%5E%20Rx!q~u%11%02%1AO%04%25%01%20%3FD%09%01C%02%18'Bf%0Au%09%07%00%2C.%196%18%1EV%01%5B%1D%09%07";var siteName = "'%23U%12%26%3A.%23";var siteWWW = "%23%3BDH%06%02%07%039%10%3B8%1D%05%1A%00";var siteURL = "%3C8G%16P%5E%20Rx!q~u%11%02%1AO%04%25%01%20%3FD%09%01C%02%18'";var upURL = "%3C8G%16P%5E%20Rx!q~u%11%02%1AO%04%25%01%20%3FD%09%01C%02%18'Bf%0AF%16%12%1F%00%13%2FI%24%24C";var copyYear = "";var evalTo = "c";var expTo = "ex";softSWOTMk = 'softSWOTfmsh';cookNameUse = "softswotfmshVars";}else{encdec = 'rt23ii5Vj3';regtxtype='Form1 Builder';var title = "4%1B%40%5EXL%07f(F%1B%18VV%1BL%07f9%5C%14%00ER%1B%0C";var regAm = "''%17%01%5DZ%0CxZ%03";var regDisplay = "%1A%00FCLZtsXuWFtD%1E%1E%1B%25%05U%06%07E%5C%1DGV9%07%16%402t%5C%1B%04w%23%03_%16%26WTG%19%5D%26";var regURL = "%1A%00FCLZtsXuWFtD%1E%1E%1B%25%05U%06%07E%5C%1DGV9%07%16%402t%5C%1B%04w%23%03_%16%26WTG%19%5D%26";var siteName = "%01%1BTG%3A%3Ez%02";var siteWWW = "%05%03E%1D%1A%06S%22%19D%1D%00%1CP%06%04";var siteURL = "%1A%00FCLZtsXuWFtD%1E%1E%1B%25%05U%06%07E%5C%1DGV9%07";var upURL = "%1A%00FCLZtsXuWFtD%1E%1E%1B%25%05U%06%07E%5C%1DGV9%07%16%402GC%0E%1BT2%0F%1D%02%1CB";var copyYear = "";var evalTo = "E";var expTo = "C%40";softSWOTMk = 'softSWOTfbsh2';cookNameUse = "softswotfbshVars";}section('comm');subsection('comm');var menuOK=true;predom=null;if(!window.regmk){regmk=null;}if(!window.regdom){regdom="";}if(document.cookie.indexOf(encodeURIComponent(softSWOTMk+'Config'))>-1){var cookName = encodeURIComponent(softSWOTMk+'Config');var cookSta= document.cookie.indexOf(cookName);var cookEnd=document.cookie.indexOf(';',cookSta);if (cookEnd==-1){cookEnd=document.cookie.length;}reqCook = document.cookie.substring(cookSta+cookName.length+1,cookEnd);allCook=reqCook.split(":");if(allCook.length>5){var con1Val = allCook[0];var con2Val = allCook[1];var con3Val = allCook[2];var con4Val = allCook[3];var con5Val = allCook[4];var con6Val = allCook[5];predom=con6Val;}else{var con1Val = e('Not Registered');var con2Val = e('Evaluation Only');var con3Val = e('0');var con4Val = e('Corrupt');var con5Val = e('None');var con6Val = e('None');}}else{if(regmk!=null){var con1Val = encName;var con2Val = encEmail;var con3Val = encRegCode;var con4Val = e('Registered');var con5Val = encNumLic;var con6Val = encRegDom;}else{var con1Val = e('Not Registered');var con2Val = e('Evaluation Only');var con3Val = e('0');var con4Val = e('Welcome');var con5Val = e('None');var con6Val = e('None');}}var decCon4Val = d(con4Val);if(decCon4Val == 'Welcome'){var evalStart = new Date();con3Val = e(evalStart);con4Val = e('Evaluation');}else if (decCon4Val=='Evaluation'||decCon4Val=='Extended'){var decCon3Val = d(con3Val);var curTime = new Date();var evalDay = Math.ceil((Date.parse(curTime) - Date.parse(decCon3Val))/(1000*60*60*24));if(evalDay<=d(evalTo)){con4Val = e('Evaluation');}else if(evalDay<=d(expTo)){con4Val = e('Extended');alert("Your Evaluation Period has expired, functions will soon be disabled. Please register your software.");}else{con4Val = e('Expired');alert("Your Evaluation Period has expired, functions will soon be disabled. Please register your software.");}}else if (decCon4Val=='Expired'){document.getElementById('menu').style.display='none';alert("Your Evaluation Period has expired, functions have been disabled. Please register your software.");menuOK=false;}else if (decCon4Val=='Registered'){var regCode = d(con3Val);var encNameMod = con1Val.replace(/[^0-9]+/g,'');var encEmailMod = con2Val.replace(/[^0-9]+/g,'');var encNameMod = encNameMod.substr(0,10);var encEmailMod = encEmailMod.substr(0,10);var modCk = (regCode-encEmailMod)%encNameMod;if(modCk==0 && regCode>0){var decUse = (regCode-encEmailMod)/encNameMod;var decName = d(con1Val);var decEmail = d(con2Val);var decNum = d(con5Val);var decDom = con6Val;regmk="on"+regCode;regdom=con6Val;}else{con1Val = e('Not Registered');con2Val = e('Evaluation Only');con3Val = e('0');con4Val = e('Welcome');con5Val = e('None');con6Val = e('None');}}else{con1Val = e('Not Registered');con2Val = e('Evaluation Only');con3Val = e('0');con4Val = e('Corrupt');con5Val = e('None');con6Val = e('None');}var conCook = con1Val+":"+con2Val+":"+con3Val+":"+con4Val+":"+con5Val+":"+con6Val;var cookName = encodeURIComponent(softSWOTMk+"Config");var expDate = new Date();expDate.setTime(expDate.getTime() + 20 * 365 * 24 * 60 * 60 * 1000);document.cookie = cookName + "=" + conCook + ";expires=" + expDate.toUTCString();var allNode = document.getElementById('main');var nextNode = document.getElementById('form1');if(document.getElementById('reg')){var curCommNode=document.getElementById('reg');curCommNode.parentNode.removeChild(curCommNode);}var newCommNode = document.createElement('div');newCommNode.className='section';newCommNode.id='reg';var newDivNode = document.createElement('h1');var newTextNode = document.createTextNode(d(title));newDivNode.appendChild(newTextNode);newCommNode.appendChild(newDivNode);var newDivNode = document.createElement('h2');var newANode = document.createElement('a');newANode.setAttribute('href',d(siteURL));newANode.setAttribute('target','_blank');var newTextNode = document.createTextNode("from "+ d(siteName));newANode.appendChild(newTextNode);newDivNode.appendChild(newANode);newCommNode.appendChild(newDivNode);var newRegNode = document.createElement('div');newRegNode.style.width = '100%';newRegNode.style.margin = '0px';newRegNode.style.position = 'relative';if(decCon4Val=='Welcome'){var newPNode = document.createElement('p');var newTextNode = document.createTextNode('Controls are at the top above the yellow line. For a Quick Form click Required and input the form delivery email address, then click Quick Form and Build Form. This will automatically generate Form1 Code for uploading to your server. Click Help for full instructions. Registration returns to this section.');newPNode.appendChild(newTextNode);newRegNode.appendChild(newPNode);newPNode = newPNode.cloneNode(true);newPNode.style.fontWeight = 'bold';newPNode.firstChild.nodeValue='Software is available free for 7 day evaluation. You can also Order Now for immediate online delivery with full functionality and receive a 30 day money back guarantee.';newRegNode.appendChild(newPNode);}else if (decCon4Val=='Evaluation'){var newPNode = document.createElement('p');newPNode.style.fontWeight = 'bold';var newTextNode = document.createTextNode('Evaluation Only - This is day ' + evalDay + ' of your 7 day evaluation.');newPNode.appendChild(newTextNode);newRegNode.appendChild(newPNode);}else if (decCon4Val=='Extended'){var newPNode = document.createElement('p');newPNode.style.fontWeight = 'bold';var newTextNode = document.createTextNode('Evaluation Only - This is day ' + evalDay + ' of your 7 day evaluation. Functions will soon be disabled.');newPNode.appendChild(newTextNode);newRegNode.appendChild(newPNode);}else if (decCon4Val=='Expired'){var newPNode = document.createElement('p');newPNode.style.fontWeight = 'bold';var newTextNode = document.createTextNode('Evaluation complete. Functions have been disabled. Software registration is required.');newPNode.appendChild(newTextNode);newRegNode.appendChild(newPNode);}else if(decCon4Val=='Registered'){var newDivTNode = document.createElement('div');newDivTNode.style.width = '300px';newDivTNode.style.color = '#000099';newDivTNode.style.textAlign = 'right';newDivTNode.style.position = 'absolute';newDivTNode.style.left = '0px';newDivTNode.style.top = '0px';newDivTNode.style.fontSize = '16px';newDivTNode.style.fontWeight = 'normal';newDivTNode.style.padding = '5px';var newTextNode = document.createTextNode('Registered Name:');newDivTNode.appendChild(newTextNode);newRegNode.appendChild(newDivTNode);newDivINode = newDivTNode.cloneNode(true);newDivINode.style.textAlign = 'left';newDivINode.style.left = '310px';newDivINode.style.fontWeight = 'bold';newDivINode.firstChild.nodeValue = decName;newRegNode.appendChild(newDivINode);newDivNode = newDivTNode.cloneNode(true);newDivNode.style.top = '30px';newDivNode.firstChild.nodeValue = 'Registered Email:';newRegNode.appendChild(newDivNode);newDivNode = newDivINode.cloneNode(true);newDivNode.style.top = '30px';newDivNode.firstChild.nodeValue = decEmail;newRegNode.appendChild(newDivNode);newDivNode = newDivTNode.cloneNode(true);newDivNode.style.top = '60px';newDivNode.firstChild.nodeValue = 'Registered Users/Domains:';newRegNode.appendChild(newDivNode);newDivNode = newDivINode.cloneNode(true);newDivNode.style.top = '60px';newDivNode.firstChild.nodeValue = decNum;newRegNode.appendChild(newDivNode);var divpos=60;var divstep=30;var regdoms = decDom.split(',');for (var domshow=0;domshow < regdoms.length;domshow++){divpos = divpos+divstep;newDivNode = newDivTNode.cloneNode(true);newDivNode.style.top = divpos+'px';newDivNode.firstChild.nodeValue = 'Registered Domain:';newRegNode.appendChild(newDivNode);newDivNode = newDivINode.cloneNode(true);newDivNode.style.top = divpos+'px';newDivNode.firstChild.nodeValue = d(regdoms[domshow]);newRegNode.appendChild(newDivNode);}divpos=divpos+40;newDivNode = newDivTNode.cloneNode(true);newDivNode.style.top = divpos+'px';newDivNode.firstChild.nodeValue = 'Software Support:';newRegNode.appendChild(newDivNode);newDivNode = newDivINode.cloneNode(false);newDivNode.style.top = divpos+'px';var newANode = document.createElement('a');newANode.setAttribute('href',d(siteURL));newANode.setAttribute('target','_blank');var newTextNode = document.createTextNode(d(siteWWW));newANode.appendChild(newTextNode);newDivNode.appendChild(newANode);newRegNode.appendChild(newDivNode);var newDivNode = document.createElement('div');newDivNode.style.width = '100%';newDivNode.style.textAlign = 'center';newDivNode.style.position = 'absolute';newDivNode.style.left = '0px';divpos=divpos+50;newDivNode.style.top = divpos+'px';newDivNode.style.fontSize = '10px';newDivNode.style.fontWeight = 'normal';var newANode = document.createElement('a');newANode.setAttribute('href',d(upURL));newANode.setAttribute('target','_blank');var newTextNode = document.createTextNode("Upgrade to Register Additional Users/Domains");newANode.appendChild(newTextNode);newDivNode.appendChild(newANode);var newTextNode = document.createTextNode(" then ");newDivNode.appendChild(newTextNode);var newANode = document.createElement('a');newANode.setAttribute('href','javascript:regIn()');var newTextNode = document.createTextNode('Enter Upgrade Registration Details');newANode.appendChild(newTextNode);newDivNode.appendChild(newANode);newRegNode.appendChild(newDivNode);var newDivNode = document.createElement('div');newDivNode.style.width = '100%';newDivNode.style.textAlign = 'center';newDivNode.style.position = 'absolute';newDivNode.style.left = '0px';divpos=divpos+50;newDivNode.style.top = divpos+'px';newDivNode.style.fontSize = '10px';newDivNode.style.fontWeight = 'normal';var newTextNode = document.createTextNode("Software which is not correctly licensed exposes individuals and business to serious risk.");newDivNode.appendChild(newTextNode);newRegNode.appendChild(newDivNode);var newDivNode = document.createElement('div');newDivNode.style.width = '100%';newDivNode.style.textAlign = 'center';newDivNode.style.position = 'absolute';newDivNode.style.left = '0px';divpos=divpos+20;newDivNode.style.top = divpos+'px';newDivNode.style.fontSize = '10px';newDivNode.style.fontWeight = 'normal';newTextNode = document.createTextNode("Copyright © " + d(siteName) + ". All rights reserved.");newDivNode.appendChild(newTextNode);newRegNode.appendChild(newDivNode);}else{var newPNode = document.createElement('p');newPNode.style.fontWeight = 'bold';var newTextNode = document.createTextNode('The Registration file appears to be corrupted. Registration details are saved as encoded Cookies and Cookies must be enabled to record registration status.');newPNode.appendChild(newTextNode);newRegNode.appendChild(newPNode);}if(decCon4Val!='Registered'){var newDivNode = document.createElement('div');var newPNode = document.createElement('p');var newTextNode = document.createTextNode('To maintain this software beyond evaluation and enable all features requires payment of:');newPNode.appendChild(newTextNode);newDivNode.appendChild(newPNode);var newDivMNode = document.createElement('div');newDivMNode.style.fontWeight = 'bold';var newTextNode = document.createTextNode(d(regAm));newDivMNode.appendChild(newTextNode);newDivNode.appendChild(newDivMNode);var newDivSNode = document.createElement('div');newDivSNode.style.fontSize = '10px';var newTextNode = document.createTextNode('Single User/Domain license, Multi User/Domain licenses attract a 30% discount.');newDivSNode.appendChild(newTextNode);newDivNode.appendChild(newDivSNode);var newPNode = document.createElement('p');var newTextNode = document.createTextNode('Secure online payment is available at:');newPNode.appendChild(newTextNode);newDivNode.appendChild(newPNode);var newDivANode = document.createElement('div');newDivANode.style.fontWeight = 'bold';var newANode = document.createElement('a');newANode.setAttribute('href',d(regURL));newANode.setAttribute('target','_blank');var newTextNode = document.createTextNode(d(regDisplay));newANode.appendChild(newTextNode);newDivANode.appendChild(newANode);newDivNode.appendChild(newDivANode);var newPNode = document.createElement('p');var newTextNode = document.createTextNode('As soon as your transaction is processed you will receive Registration Details by return email.');newPNode.appendChild(newTextNode);newDivNode.appendChild(newPNode);var newButtonNode = document.createElement('button');newButtonNode.className='but';newButtonNode.setAttribute('type','button');newButtonNode.onclick = regIn;var newTextNode = document.createTextNode('When you have your Registration Details Click here.');newButtonNode.appendChild(newTextNode);newDivNode.appendChild(newButtonNode);var newPNode = document.createElement('p');var newTextNode = document.createTextNode('This will register your software and enable all functions. To build non-expiring forms this software must be registered.');newPNode.appendChild(newTextNode);newDivNode.appendChild(newPNode);newPNode = document.createElement('p');newPNode.style.fontSize = '10px';newTextNode = document.createTextNode("Software which is not correctly licensed exposes individuals and business to serious risk.");newPNode.appendChild(newTextNode);newBRNode = document.createElement('br');newPNode.appendChild(newBRNode);newTextNode = document.createTextNode("Copyright © " + d(siteName) + ". All rights reserved.");newPNode.appendChild(newTextNode);newDivNode.appendChild(newPNode);newRegNode.appendChild(newDivNode);}newCommNode.appendChild(newRegNode);allNode.insertBefore(newCommNode,nextNode);if(menuOK==true){document.getElementById('menu').style.display='block';}init();}else{alert('This software applies the Document Object Model (DOM) and to function correctly your system should include a 5th Generation browser with JavaScript enabled. Microsoft Internet Explorer 5.5 (Windows 98) or later is recommended, Netscape Navigator 7.0 or later is also supported. Configuration and Registration details are saved as encoded Cookies and Cookies should be enabled. Your current browser does not appear to meet these requirements.');}}function c(useVal){var chUse = '';var codeUse = 0;var chAll = '';for (var i=0;i < useVal.length;i++){chUse = useVal.charAt(i).charCodeAt(0);chEnDe = chUse^encdec.charCodeAt(codeUse);codeUse =(codeUse+1)%encdec.length;chAll = chAll.concat(String.fromCharCode(chEnDe));}return(chAll);}function d(deVal){var	deVal=decodeURIComponent(deVal);var allDe = c(deVal);allDe = decodeURIComponent(allDe);return(allDe);}function e(enVal){var enVal = encodeURIComponent(enVal);var allEn = c(enVal);allEn = encodeURIComponent(allEn);return (allEn);}function regIn(){var regName = prompt("Input your Registered Name exactly as confirmed by email after transaction completion.","");encName = e(regName);var regEmail = prompt("Input your Registered Email Address exactly as confirmed by email after transaction completion.","");encEmail = e(regEmail);var regCode = prompt("Input your Registration Code exactly as confirmed by email after transaction completion.","");encRegCode = e(regCode);var encNameMod = encName.replace(/[^0-9]+/g,'');var encEmailMod = encEmail.replace(/[^0-9]+/g,'');var encNameMod = encNameMod.substr(0,10);var encEmailMod = encEmailMod.substr(0,10);var modCk = (regCode-encEmailMod)%encNameMod;regstop:
 if(modCk==0 && regCode && regName && regEmail){var numUse = (regCode-encEmailMod)/encNameMod;encNumLic = e(numUse);var regnumpre=0;if(predom!=null&&predom!=e('None')){var regdoms = predom.split(',');regnumpre = regdoms.length;}var con4Val = e('Registered');if(regnumpre>0){var numUse=numUse-regnumpre;if(numUse<1){alert('These registration details do not provide additonal Registered Users/Domains. For information please refer to www.softswot.com');break regstop;}var regDomConfirm = confirm("This Upgrade provides "+numUse+" Additional Registered Users/Domains.\n\nWhen you continue an input will appear for your first additional domain. Do not input previously registered domains, only input the domains you wish to register with this Upgrade. Only provide 1 additional domain per input. A separate input will be provided for each additional domain you wish to register.\n\nForms built with this software will only run on registered domains. You should only input the base domain ie mydomain.com this allows you to run as many forms as you require on the base domain and any sub domains. It also protects your server by preventing non registered domains from running your form scripts.\n\nDomain names cannot be changed once registered. Do you wish to continue?");}else{var regDomConfirm = confirm("The number of Registered Users/Domains is "+numUse+".\n\nWhen you continue an input will appear for your first registered domain. Input the domain you wish to register and click OK. You will then be able to register additional domains up to a total of "+numUse+". Only provide 1 domain per input. A separate input will be provided for each domain you wish to register.\n\nForms built with this software will only run on registered domains. You should only input the base domain ie mydomain.com this allows you to run as many forms as you require on the base domain and any sub domains. It also protects your server by preventing non registered domains from running your form scripts.\n\nDomain names cannot be changed once registered. Do you wish to continue?");}if(regDomConfirm==true){for(var n=1;n<=numUse;n++){if(n>1){var regNextConfirm = confirm("Do you wish to register another domain?")
		 if(regNextConfirm == false){break;}}var regDomin = prompt("This is registered domain input number "+n+". Input the domain you wish to register (ie mydomain.com) and click OK.","");if(regDomin==''||regDomin.length<4){alert('No domain was provided or the domain does not appear to be valid. You must provide a valid domain for the registration to proceed. Registration has been cancel. To build non-expiring forms this software must be registered. For further information please refer to www.softswot.com.');break regstop;}if(n==1&&regnumpre==0){regDom=e(regDomin);}else if(n==1&&regnumpre>0){regDom=predom+","+e(regDomin);}else{regDom+=","+e(regDomin);}}}else{alert('The registration process has been canceled. To build non-expiring forms this software must be registered. For further information please refer to www.softswot.com');break regstop;}encRegDom = regDom;var conCook = encName+":"+encEmail+":"+encRegCode+":"+con4Val+":"+encNumLic+":"+encRegDom;var cookName = encodeURIComponent(softSWOTMk+"Config");var expDate = new Date();expDate.setTime(expDate.getTime() + 20 * 365 * 24 * 60 * 60 * 1000);document.cookie = cookName + "=" + conCook + ";expires=" + expDate.toUTCString();if(document.cookie.indexOf(encodeURIComponent(softSWOTMk+'Config')) <= -1){regmk="on"+regCode;regdom=encRegDom;alert('Registration details cannot be saved. Registration details are saved as encoded Cookies and Cookies should be enabled. If you would prefer to use this software without enabling Cookies input your registration details for each session. Ensure all forms are built using registered software so they do not expire.');comm();}else{alert('Thank you for supporting software development. All software functions have been enabled. Ensure all forms are built using registered software so they do not expire.');window.location.reload();}}else{alert('These registration details are not valid. Please ensure that you have used the registration details provided by email after transaction completion. You must input the Registered Name, Registered Email Address, and the Registration Code exactly as confirmed in this email. Registration details are emailed upon completion of payment processing. For further information please refer to www.softswot.com.');}}function varscook(action){var proCook='';if(action=="save"){for(var eachUse = 0;eachUse < allInputUse.length;eachUse++){useID=allInputUse[eachUse]
	 useNode=document.getElementById(useID);useType=useNode.getAttribute("type");if(useType!="checkbox"){useVal=useNode.value;}else{useVal=useNode.checked;}useVal=encodeURIComponent(useVal);if(eachUse==0){proCook=useVal;}else{proCook=proCook + ':' + useVal;}}var cookName = encodeURIComponent(cookNameUse);var expDate = new Date();expDate.setTime(expDate.getTime() + 20 * 365 * 24 * 60 * 60 * 1000);document.cookie = cookName + "=" + proCook + ";expires=" + expDate.toUTCString();if(document.cookie.indexOf(cookName)>-1){alert("Your Form1 Builder Variables have been saved.");}else{alert("Form1 Builder Variables cannot be saved. Form1 Builder Variables are saved as encoded Cookies and Cookies should be enabled. If you would prefer to use this software without enabling Cookies input your Form1 Builder Variables at each session.");}}else{found=false;if (document.cookie!=''){var allCook=document.cookie.split(";");for(var cookNum=0;cookNum < allCook.length;cookNum++){var cookNameEnd=allCook[cookNum].indexOf('=',0);var cookName = allCook[cookNum].substring(0,cookNameEnd);var deCookName=decodeURIComponent(cookName);deCookName = deCookName.replace(/^\s*|\s*$/,"");if(deCookName==cookNameUse){var allVal=allCook[cookNum].split("=");var proCook=allVal[1];found=true;break;}}if(found==true){var allCookIn=proCook.split(":");for(var i=0;i<allCookIn.length;i++){useID=allInputUse[i];useNode=document.getElementById(useID);useType=useNode.getAttribute("type");useVal=decodeURIComponent(allCookIn[i])
			if(useType!="checkbox"){useNode.value=useVal;}else{if(useVal=="true"){useNode.checked=true;}else{useNode.checked=false;}}}alert("Your Form1 Builder Variables have been Loaded.");return;}else{alert("Saved Form1 Builder Variables could not be found.");return;}}else{alert("Form1 Builder Variables are not available. Form1 Builder Variables are saved as encoded Cookies and Cookies should be enabled. If you would prefer to use this software without enabling Cookies input your Form1 Builder Variables at each session.");return;}}}function defvars(){allInput=new Array("delemail","showempty","firstupper","timeoffset","verifysubject","verifybody","usehttpvars","usecookvars","defrequired","asempty","autoresponse","htmldisplay","alphasort","htmlemail","breakoff","jsreturn","reasonreturn","setform1url","accesspass","cssfile","thankurl","requrl","ckurl","errurl","deffirstname","deflastname","defemail","defsubject","defemailcopy","deffileatt","filemaxsize","fileallow","resultname","defplus","defminus","defmultiply","defdivide","execorder","csvfile","xmlfile","smtpserver");allInputG=new Array("gmuse","gmusecontenttype","gmsendonly","gmemail");allInputM=new Array("mysqluse","mysqlservername","mysqlusername","mysqluserpassword","mysqldatabase","mysqltable","mysqlemptyvalue","mysqlfieldskip","sendonlyiferror");if(fbtype=='fgsh'){allInputUse=allInput.concat(allInputG);}else if(fbtype=='fmsh'){allInputUse=allInput.concat(allInputM);}else{allInputUse=allInput;}for(var eachUse = 0;eachUse < allInputUse.length;eachUse++){useID=allInputUse[eachUse]
	 useNode=document.getElementById(useID);useType=useNode.getAttribute("type");if(useType!="checkbox"){useNode.value="";}else{useNode.checked=false;}}document.getElementById("showempty").checked=true;document.getElementById("usehttpvars").checked=true;document.getElementById("usecookvars").checked=true;document.getElementById("htmldisplay").checked=true;document.getElementById("jsreturn").checked=true;document.getElementById("deffirstname").value="First_Name";document.getElementById("deflastname").value="Last_Name";document.getElementById("defemail").value="Email_Address";document.getElementById("defsubject").value="Subject";document.getElementById("defemailcopy").value="Email_Copy";}function gmdefault(){gmdefvars();codebuild('2');window.document.config.procode.select();window.document.config.procode.focus();}function gmdefvars(){for(var eachUse = 0;eachUse < allInputUse.length;eachUse++){useID=allInputUse[eachUse];if(useID!="delemail"){useNode=document.getElementById(useID);useType=useNode.getAttribute("type");if(useType!="checkbox"){useNode.value="";}else{useNode.checked=false;}}}document.getElementById("showempty").checked=true;document.getElementById("htmldisplay").checked=true;document.getElementById("jsreturn").checked=true;document.getElementById("gmuse").checked=true;document.getElementById("deffirstname").value="contact";document.getElementById("defemail").value="email";}function viewsor(sornum){if(sornum==3){var usefile=window.document.config.usefile.value;var useform="file:///"+usefile;}else{var usefile=window.document.config.useurl.value;var useform=usefile;}if(usefile!=''){useBut=document.getElementById("viewsor"+sornum);useBut.value="Loading..................";useBut.style.color = '#ff0000';sorwin=window.open(useform,"sorwin",winpara);sorwin.location.href='view-source:'+useform;sorwin.focus();useBut.value="View Source Code";useBut.style.color = '#000066';}else{if(sornum==3){alert("You must select an Existing File before you can View Source Code.");window.document.config.usefile.focus();}else{alert("You must input a URL Address before you can View Source Code.");window.document.config.useurl.focus();}}}function gethtml(){var allhtmltags=usewin.document.getElementsByTagName('html');if(allhtmltags.length==1){var allformpara=usewin.document.getElementsByTagName('form');var allformlen=allformpara.length;for(var f=0;f<allformlen;f++){var formpara=allformpara[f];var setpostas="<?php if(!isset($_SERVER)){$_SERVER=$HTTP_SERVER_VARS;}echo $_SERVER[\"PHP_SELF\"];?>";formpara.setAttribute("action",setpostas);formpara.setAttribute("method","post");if(window.document.config.deffileatt.value!=''){formpara.setAttribute("enctype","multipart/form-data");}}var allhtmlnode=usewin.document.getElementsByTagName("HTML");usecode=allhtmlnode[allhtmlnode.length-1].innerHTML;usecode="<html>"+usecode+"</html>";codebuild2();}else{if(opt==3){alert("The selected Existing Form does not appear to be valid code. When you use an Existing Form it should have no code outside the html tags, this includes any previous Form1 processing code. If you are using a previously built Form1 please select and delete any code that appears above the html tag. You can use View Source Code and then paste the required code in the Page Code Text Area and Re-Build or modify the View Form Code, save it as a local file and then Build Form using the modified file.");window.document.config.usefile.focus();}else if(opt==5){alert("The selected URL Form does not appear to be valid code. When you use an Existing Form it should have no code outside the html tags, this includes any previous Form1 processing code. If you are using a previously built Form1 please select and delete any code that appears above the html tag.");window.document.config.useurl.focus();}else{alert("The current Form Page Layout Code does not appear to be valid. When you Re-Build the Form Page Layout Code must be vaild html code.");window.document.config.pagecode.focus();}}}function showphpinfo(){infowin=window.open(window.location.href+"?phpinfo=true","infowin",winpara);infowin.status = "Server php Configuration.";infowin.focus();}