From 8e38755040c6c2073f92f0ffb087da530d0e7a0a Mon Sep 17 00:00:00 2001
From: ftimme <ft@falkotimme.com>
Date: Mon, 12 Nov 2012 11:49:26 -0500
Subject: [PATCH] - Changed a German translation. - Extended SEO redirect check for subdomains/alias domains.

---
 server/lib/classes/db_mysql.inc.php |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/server/lib/classes/db_mysql.inc.php b/server/lib/classes/db_mysql.inc.php
index 18f09bf..4c75e62 100644
--- a/server/lib/classes/db_mysql.inc.php
+++ b/server/lib/classes/db_mysql.inc.php
@@ -1,4 +1,3 @@
-
 <?php
 /*
    Copyright (c) 2005, Till Brehm, projektfarm Gmbh
@@ -104,7 +103,8 @@
   }
 
   public function query($queryString) {
-    $this->queryId = parent::query($queryString);
+    parent::ping();
+	$this->queryId = parent::query($queryString);
     $this->updateError('DB::query('.$queryString.') -> mysqli_query');
     if(!$this->queryId) {
       return false;
@@ -226,10 +226,10 @@
     if(is_array($record_old) && count($record_old) > 0) {
       foreach($record_old as $key => $val) {
 	// if(!isset($record_new[$key]) || $record_new[$key] != $val) {
-	if($record_new[$key] != $val) {
+	if(@$record_new[$key] != $val) {
 	  // Record has changed
 	  $diffrec_full['old'][$key] = $val;
-	  $diffrec_full['new'][$key] = $record_new[$key];
+	  $diffrec_full['new'][$key] = @$record_new[$key];
 	  $diff_num++;
 	} else {
 	  $diffrec_full['old'][$key] = $val;
@@ -276,9 +276,9 @@
 
 
 	if($diff_num > 0) {
-		$diffstr = $app->db->quote(serialize($diffrec_full));
+		$diffstr = $this->quote(serialize($diffrec_full));
 		if(isset($_SESSION)) {
-			$username = $app->db->quote($_SESSION['s']['user']['username']);
+			$username = $this->quote($_SESSION['s']['user']['username']);
 		} else {
 			$username = 'admin';
 		}
@@ -288,7 +288,7 @@
 		if($action == 'UPDATE') $action = 'u';
 		if($action == 'DELETE') $action = 'd';
 		$sql = "INSERT INTO sys_datalog (dbtable,dbidx,server_id,action,tstamp,user,data) VALUES ('".$db_table."','$dbidx','$server_id','$action','".time()."','$username','$diffstr')";
-		$app->db->query($sql);
+		$this->query($sql);
 	}
 
       return true;
@@ -593,4 +593,4 @@
 
 	      }
 
-	      ?>
+	      ?>
\ No newline at end of file

--
Gitblit v1.9.1