Location: PHPKode > projects > WorkOrder TS > workorder-ts/include/pro/workorder_config_save_conf-free.inc.php
<?PHP $inc_dir='../';require_once $inc_dir.'magic_quotes.php';$_Il6fL=Null;require $inc_dir.'config-user.inc.php';require $inc_dir.'conn-string-user.inc.php';require_once $inc_dir.'workorder_function_isuserauthenticated.inc.php';require_once $inc_dir.'workorder_function_general.inc.php';$CONF=_OFB10($inc_dir);$SSID=mysql_real_escape_string($_GET['SSID']);$_jL8tj=_OFPDC($self);if( $SSID=="" ) { $SSID=mysql_real_escape_string($_POST['SSID']);} if( file_exists("$inc_dir/pro/workorder_functions_pro.inc.php")==False ) { $sql="select COUNT(*) AS COUNT from ".$CONF['TableNameUsers']." where User_chksum='' OR User_chksum IS NULL";$res=mysql_query($sql,$conn) or die("Error 32156chk2");$row=mysql_fetch_array($res);$_jjQIo=$row['COUNT'];if( $_jjQIo !=0 ) { die("Invalid User accounts found, maybe it's time to purchase the Professional edition instead of screwing with the database. The Professional edition allows custom user accounts. The software is now locked until the Professional edition is installed or until the unlicensed accounts are removed. <a href=\"http://www.WorkOrderTS.com\">http://www.WorkOrderTS.com</a>");   }  }   if( _L00CR($SSID,$inc_dir,$_Il6fL, $CONF) == "FAILED" ) {   $_Ilo8J = addslashes($_SERVER['PHP_SELF']);   $_IlC1t = addslashes($_SERVER['QUERY_STRING']);   $TargetQueryPass = str_replace('=','\=',$_IlC1t);   echo("<BR>TargetURL:".$_Ilo8J);   echo("<br>Target Query: $_IlC1t<br>Self: $_jL8tj");   die('<html> <head> <meta http-equiv="refresh" content="0; url='.$_jL8tj.'login.php?TargetURLPass='.$_Ilo8J.'&amp;TargetQueryPass='.$TargetQueryPass.'"> </head> <body> <br>Connecting...<br>'.$_jL8tj.'login.php?TargetURLPass='.$_Ilo8J.'&amp;TargetQueryPass='.$TargetQueryPass.'<BR> </body> </html>');  }  if( _L01LO($SSID,$inc_dir,4, $CONF) == False ) {   die('<html><head></head><body>You are not allowed to be here</body></html>');  }  if( file_exists("$inc_dir/pro/workorder_functions_pro.inc.php") == False ) {   $sql = "select COUNT(*) AS COUNT from ".$CONF['TableNameUsers']." where User_chksum='' OR User_chksum IS NULL";   $res = mysql_query($sql,$conn) or die("Error 32156chk2");   $row = mysql_fetch_array($res);   $_jjQIo = $row['COUNT'];   if( $_jjQIo != 0 ) {     die("Invalid User accounts found, maybe it's time to purchase the Professional edition instead of screwing with the database. The Professional edition allows custom user accounts. The software is now locked until the Professional edition is installed or until the unlicensed accounts are removed. <a href=\"http://www.WorkOrderTS.com\">http://www.WorkOrderTS.com</a>");} } if( isset($_POST['CompanyNameTXTValue'])==False ) { die("Error: required information has not been passed! You should only see this message if you session timed out and the login script is trying to redirect you to the Control Panel save page. If this is not the case, please report the error or go back to the Control Panel and try again.....");} $_J86Ol=mysql_real_escape_string($_POST['CompanyLogoLocationTXTValue']);$_J8661=mysql_real_escape_string($_POST['CompanyNameTXTValue']);$_J8f6i=mysql_real_escape_string($_POST['BackStopContTXTValue']);$_J886f=mysql_real_escape_string($_POST['Disclaimer_CheckinTXTValue']);$_J88fI=mysql_real_escape_string($_POST['Rate_OnsiteTXTValue']);$_J8tIj=mysql_real_escape_string($_POST['Rate_InstoreTXTValue']);$_J8OQj=mysql_real_escape_string($_POST['UpdateTicketDelayMinTXTValue']);$_J8o1o=1;$_J8oLo=mysql_real_escape_string($_POST['AuthenticationTimeoutMinTXT']);$_J8C1L=mysql_real_escape_string($_POST['MappingService']);$_jtoC0[0]=mysql_real_escape_string($_POST['StoreName0']);$_J8iI1[0]=mysql_real_escape_string($_POST['GoogleAddress0']);echo("<br>Updating Configuration....<br>");if( file_exists("$inc_dir/pro/workorder_functions_pro.inc.php")==False ) { $sql="select COUNT(*) AS COUNT from ".$CONF['TableNameUsers']." where User_chksum='' OR User_chksum IS NULL";$res=mysql_query($sql,$conn) or die("Error 32156chk2");$row=mysql_fetch_array($res);$_jjQIo=$row['COUNT'];if( $_jjQIo !=0 ) { die("Invalid User accounts found, maybe it's time to purchase the Professional edition instead of screwing with the database. The Professional edition allows custom user accounts. The software is now locked until the Professional edition is installed or until the unlicensed accounts are removed. <a href=\"http://www.WorkOrderTS.com\">http://www.WorkOrderTS.com</a>");   }  }   $x=0;  $_J8LC1[$x] = $_POST["Address$x"];  $_J8LC1[$x] = mysql_real_escape_string($_J8LC1[$x]);  $sql = "update $TableConfig set config_value='$_J8LC1[$x]' where config_name='Company Address$x'";  $res = mysql_query( $sql, $conn) or die("Error Updating Company Address$x with Value: $_J8LC1[$x] <br>Code: 23sd87-$x");  $sql = "update $TableConfig set config_value='$_J8661' where config_name='Company Name'";  $res = mysql_query( $sql, $conn) or die("Error Updating Company Name with Value: $_J8661 <br>Code: 23sd87");  $sql = "update $TableConfig set config_value='$_J86Ol' where config_name='Company Logo Location'";  $res = mysql_query( $sql, $conn) or die("Error Updating Company Logo Location with Value: $_J86Ol <br>Code: 943587qgszdf");  $sql = "update $TableConfig set config_value='$_J8f6i' where config_name='BackStopCont'";  $res = mysql_query( $sql, $conn) or die("Error Updating Back Stop Control with Value: $_J8f6i <br>Code: 9234hgasd");  $sql = "update $TableConfig set config_value_text='$_J886f' where config_name='Disclaimer-Checkin'";  $res = mysql_query( $sql, $conn) or die("Error Updating Disclaimer-Checkin with Value: $_J886f <br>Code: jsdfh76a");  $sql = "update $TableConfig set config_value='$_J88fI' where config_name='Rate-Onsite'";  $res = mysql_query( $sql, $conn) or die("Error Updating Onsite-Rate with Value: $_J88fI <br>Code: 3247dfg");  $sql = "update $TableConfig set config_value='$_J8tIj' where config_name='Rate-Instore'";  $res = mysql_query( $sql, $conn) or die("Error Updating Instore-Rate with Value: $_J8tIj <br>Code: 8435jghdsf");  $sql = "update $TableConfig set config_value='$_J8OQj' where config_name='UpdateTicketDelayMin'";  $res = mysql_query( $sql, $conn) or die("Error Updating UpdateTicketDelayMin with Value: $_J8OQj <br>Code: 43857fgd");  $x=0;  $sql = "update $TableConfig set config_value='$_jtoC0[$x]' WHERE config_name='StoreName$x'";  $res = mysql_query( $sql, $conn) or die("Error Updating StoreName$x with Value: $_jtoC0[$x] <br>Code: 438dfsdq2gd");  $sql = "update $TableConfig set config_value='$_J8oLo' where config_name='AuthenticationTimeoutMin'";  $res = mysql_query( $sql, $conn) or die("Error Updating AuthenticationTimeoutMin with Value: $_J8oLo <br>Code: s48fhj757fgd");  $x=0;  $sql = "update $TableConfig set config_value='$_J8iI1[$x]' where config_name='GoogleAddress$x'";  $res = mysql_query( $sql, $conn) or die("Error Updating GoogleAddress$x with Value: $_J8LlC <br>Code: asd3e2");  $sql = "update $TableConfig set config_value='$_J8C1L' where config_name='MappingService'";  $res = mysql_query( $sql, $conn) or die("Error Updating MappingService with Value: $_J8C1L <br>Code: sdfs234d14");  if( isset($_POST['AdminPassword']) ) {    $_jIoOt = addslashes($_POST['AdminPassword']);   if( $_jIoOt != "" ) {     $_jIoOt = md5($_jIoOt);    $_jOj81 = $CONF['TableNameUsers'];    $sql = "update $_jOj81 set Userpassword='$_jIoOt' where User_name='admin'";    $res = mysql_query( $sql, $conn) or die("Error Updating Admin Password <p> $sql </p>Code: sdfs244d14");   }  }   if( isset($_POST['TechPassword']) ) {    $_jIC60 = addslashes($_POST['TechPassword']);   if( $_jIC60 != "" ) {     $_jIC60 = md5($_jIC60);    $_jOj81 = $CONF['TableNameUsers'];    $sql = "update $_jOj81 set Userpassword='$_jIC60' where User_name='Tech'";    $res = mysql_query( $sql, $conn) or die("Error Updating Tech Password <p> $sql </p> Code: sdfs24d14");   }   }   $_J8l6Q = mysql_real_escape_string($_POST['TicketStubAmmount']);  if( isset($_J8l6Q) ) {   $sql = "update $TableConfig set config_value='$_J8l6Q' where config_name='TicketStubAmmount'";   $res = mysql_query( $sql, $conn) or die("Error Updating TicketStubAmmount with Value: $_J8l6Q <br>Code: sdfs564c21");  }  $_Jt01o = mysql_real_escape_string($_POST['PrintTicketWidth']);  if( isset($_Jt01o) ) {   $sql = "update $TableConfig set config_value='$_Jt01o' where config_name='PrintTicketWidth'";   $res = mysql_query( $sql, $conn) or die("Error Updating PrintTicketWidth with Value: $_Jt01o <br>Code: sdfs564d25");  }  echo('<br><a href="../../workorder.php?SSID='.$SSID.'">Done</a><br>');  ?>
Return current item: WorkOrder TS