Cleanup the indentation ... tabs and whitespace after the last pull request.

This commit is contained in:
markjcrane
2016-04-28 16:56:44 -06:00
parent f204f6189e
commit bc51cd7d1d
73 changed files with 242 additions and 244 deletions
+16 -16
View File
@@ -110,27 +110,27 @@ require_once "resources/require.php";
if (strlen(check_str($_REQUEST["domain_name"])) > 0) {
$domain_name = check_str($_REQUEST["domain_name"]);
}
if (isset($_SESSION["ldap"]["certpath"])) {
$s="LDAPTLS_CERT=" . $_SESSION["ldap"]["certpath"]["text"];
putenv($s);
}
if (isset($_SESSION["ldap"]["certkey"])) {
$s="LDAPTLS_KEY=" . $_SESSION["ldap"]["certkey"]["text"];
putenv($s);
}
$host=$_SESSION["ldap"]["server_host"]["text"];
$port=$_SESSION["ldap"]["server_port"]["numeric"];
if (isset($_SESSION["ldap"]["certpath"])) {
$s="LDAPTLS_CERT=" . $_SESSION["ldap"]["certpath"]["text"];
putenv($s);
}
if (isset($_SESSION["ldap"]["certkey"])) {
$s="LDAPTLS_KEY=" . $_SESSION["ldap"]["certkey"]["text"];
putenv($s);
}
$host=$_SESSION["ldap"]["server_host"]["text"];
$port=$_SESSION["ldap"]["server_port"]["numeric"];
$connect = ldap_connect($host)
or die("Could not connect to the LDAP server.");
//ldap_set_option($connect, LDAP_OPT_NETWORK_TIMEOUT, 10);
ldap_set_option($connect, LDAP_OPT_PROTOCOL_VERSION, 3);
//ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
//ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7);
$bind_dn = $_SESSION["ldap"]["user_attribute"]["text"]."=".$username.",".$_SESSION["ldap"]["user_dn"]["text"];
$bind_pw = $_REQUEST["password"];
//Note: As of 4/16, the call below will fail randomly. Php debug reports ldap_bind
//called below with all arguments '*uninitialized*'. However, the debugger
//single-stepping just before the failing call correctly displays all the values.
$bind = ldap_bind($connect, $bind_dn, $bind_pw );
$bind_pw = $_REQUEST["password"];
//Note: As of 4/16, the call below will fail randomly. PHP debug reports ldap_bind
//called below with all arguments '*uninitialized*'. However, the debugger
//single-stepping just before the failing call correctly displays all the values.
$bind = ldap_bind($connect, $bind_dn, $bind_pw);
if ($bind) {
$_SESSION['username'] = $username;
}
+3 -3
View File
@@ -25,7 +25,7 @@
*/
// make sure the PATH_SEPARATOR is defined
umask(2);
umask(2);
if (!defined("PATH_SEPARATOR")) {
if (strpos($_ENV["OS"], "Win") !== false) {
define("PATH_SEPARATOR", ";");
@@ -34,8 +34,8 @@
}
}
if (!isset($output_format)) $output_format = (PHP_SAPI == 'cli') ? 'text' : 'html';
if (!isset($output_format)) $output_format = (PHP_SAPI == 'cli') ? 'text' : 'html';
// make sure the document_root is set
$_SERVER["SCRIPT_FILENAME"] = str_replace("\\", '/', $_SERVER["SCRIPT_FILENAME"]);
if(PHP_SAPI == 'cli'){
+1 -1
View File
@@ -460,7 +460,7 @@ if (!class_exists('schema')) {
//set the global variable
global $db, $upgrade_data_types, $text,$output_format;
if ($format=='') $format = $output_format;
if ($format=='') $format = $output_format;
//get the db variables
$config = new config;
+7 -6
View File
@@ -67,14 +67,15 @@ if (!class_exists('switch_settings')) {
}
}
{ //connect to event socket
$esl = new event_socket;
$esl->connect($this->event_socket_ip_address, $this->event_socket_port, $this->event_socket_password);
//connect to event socket
$esl = new event_socket;
$esl->connect($this->event_socket_ip_address, $this->event_socket_port, $this->event_socket_password);
//run the api command
$result = $esl->request('api global_getvar');
} //close event socket
//run the api command
$result = $esl->request('api global_getvar');
//close event socket
fclose($fp);
//set the result as a named array
$vars = array();
+3 -3
View File
@@ -25,7 +25,7 @@
*/
// make sure the PATH_SEPARATOR is defined
umask(2);
umask(2);
if (!defined("PATH_SEPARATOR")) {
if (strpos($_ENV["OS"], "Win") !== false) {
define("PATH_SEPARATOR", ";");
@@ -34,8 +34,8 @@
}
}
if (!isset($output_format)) $output_format = (PHP_SAPI == 'cli') ? 'text' : 'html';
if (!isset($output_format)) $output_format = (PHP_SAPI == 'cli') ? 'text' : 'html';
// make sure the document_root is set
$_SERVER["SCRIPT_FILENAME"] = str_replace("\\", '/', $_SERVER["SCRIPT_FILENAME"]);
if(PHP_SAPI == 'cli'){