Browse Source

fixed config for additional domains - instalator

Piotr Labudda 9 years ago
parent
commit
13b3c27e85
1 changed files with 6 additions and 5 deletions
  1. 6 5
      SE/superedit-INSTALL_SES_PROCESY_A.php

+ 6 - 5
SE/superedit-INSTALL_SES_PROCESY_A.php

@@ -56,17 +56,18 @@ class INSTALL_SES_PROCESY_A {
 		return implode(' ', $argDomain);
 	}
 	function fetch_same_domains_for_install($SERVER_ADDRESS_SHORT) {
+		$domainList = array();
 	 	if(strlen($SERVER_ADDRESS_SHORT)==0) die('Error with server address short');
 		$res=DB::query("select SERVER_ADDRESS_IP from SES_PROCESY5_A where SERVER_ADDRESS_SHORT='".$SERVER_ADDRESS_SHORT."'");
 		while($h=DB::fetch($res)) {
 			$res2=DB::query("select SERVER_ADDRESS_SHORT from SES_PROCESY5_A where SERVER_ADDRESS_IP='".$h->SERVER_ADDRESS_IP."'");
 			while($h2=DB::fetch($res2)) {
-			 	$domain[] = $h2->SERVER_ADDRESS_SHORT;
+			 	$domainList[] = $h2->SERVER_ADDRESS_SHORT;
 			}
 		}
-		$domain[] = '127.0.0.1';
-		$domain[] = 'localhost';
-		return $domain;
+		$domainList[] = '127.0.0.1';
+		$domainList[] = 'localhost';
+		return $domainList;
 	}
 }
 
@@ -2032,7 +2033,7 @@ zasob_id=\"2\"
 ';
 
 // aliasowanie do localhosta konfigow do testow systemu
-$domainList = INSTALL_SES_PROCESY_A::get_same_domains_for_install($SERVER_ADDRESS_SHORT);// [ $SERVER_ADDRESS, localhost, 127.0.0.1, ... ]
+$domainList = INSTALL_SES_PROCESY_A::fetch_same_domains_for_install($SERVER_ADDRESS_SHORT);// [ $SERVER_ADDRESS, localhost, 127.0.0.1, ... ]
 foreach ($domainList as $domain) {
 	if ($SERVER_ADDRESS == $domain) continue;// skip main domain
 	if ('localhost' == $domain) continue;// skip localhost (127.0.0.1)