From 0732d32f508045da40fe9df607b9ef20ce2d198f Mon Sep 17 00:00:00 2001
From: xaver <xaver@ispconfig3>
Date: Tue, 06 Mar 2012 10:03:23 -0500
Subject: [PATCH] join fix - disappered in commit + Switch traffic joins, because its faster - Tested in a productive system (MySQL 5.1) as query few tausend domains 1-3 sec for Webtraffic sort, faster SQL = faster and MySQL 5.5 is much faster with joins (standard is not sorted with slow traffic querys) -> slowest part is coping the tables into temp -> more tweeks on cache... -> faster by heavy use

---
 interface/web/admin/language_complete.php |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/interface/web/admin/language_complete.php b/interface/web/admin/language_complete.php
index 63c89e7..5c071a3 100644
--- a/interface/web/admin/language_complete.php
+++ b/interface/web/admin/language_complete.php
@@ -32,6 +32,7 @@
 
 //* Check permissions for module
 $app->auth->check_module_permissions('admin');
+if($conf['demo_mode'] == true) $app->error('This function is disabled in demo mode.');
 
 //* This is only allowed for administrators
 if(!$app->auth->is_admin()) die('only allowed for administrators.');
@@ -89,7 +90,7 @@
 						$target_lang_file=ISPC_WEB_PATH.'/'.$file.'/lib/lang/'.$lang_file;
 						if(!file_exists($master_lang_file)){
 						unlink($target_lang_file);
-						$msg.="File $target_lang_file remove because does not exist in master language<br />";
+						$msg.="File $target_lang_file removed because does not exist in master language<br />";
 						}
 					}
 				}//Finish of remove the files how not exists in master language
@@ -97,7 +98,7 @@
 		}
 	}
 if($msg=='')
-$msg="No files created, remove or modified<br />";
+$msg="No files created, removed or modified<br />";
 }
 
 function merge_langfile($langfile,$masterfile) {
@@ -136,8 +137,8 @@
 	
 		$file_content = "<?php\n";
 		foreach($wb as $key => $val) {
-			$val = str_replace("'",'',$val);
-			$val = str_replace('"','',$val);
+			$val = str_replace("'","\\'",$val);
+			$val = str_replace('"','\\"',$val);
 			$file_content .= '$wb['."'$key'".'] = '."'$val';\n";
 		}
 		$file_content .= "?>\n";

--
Gitblit v1.9.1