diff options
author | M.Gergo | 2020-02-02 12:55:51 +0100 |
---|---|---|
committer | M.Gergo | 2020-02-02 12:55:51 +0100 |
commit | 35283d60ca832c8c9c351ddd78cf9c5396ff80f6 (patch) | |
tree | 5dad19eb0b8298ec3a593c0383ec2aa603f89425 /mayor-orig/mayor-base | |
parent | 2116314871e4f4bbcb5aea67c455b87595f8e9da (diff) | |
download | mayor-rev4604.tar.gz mayor-rev4604.zip |
Rev: 4604rev4604
Diffstat (limited to 'mayor-orig/mayor-base')
-rw-r--r-- | mayor-orig/mayor-base/log/mayor-base.rev | 2 | ||||
-rw-r--r-- | mayor-orig/mayor-base/www/include/base/config.php | 5 | ||||
-rw-r--r-- | mayor-orig/mayor-base/www/include/base/log.php | 3 | ||||
-rw-r--r-- | mayor-orig/mayor-base/www/include/base/mysql.php | 6 |
4 files changed, 11 insertions, 5 deletions
diff --git a/mayor-orig/mayor-base/log/mayor-base.rev b/mayor-orig/mayor-base/log/mayor-base.rev index 61a4c0c1..7561799f 100644 --- a/mayor-orig/mayor-base/log/mayor-base.rev +++ b/mayor-orig/mayor-base/log/mayor-base.rev @@ -1 +1 @@ -4599 +4604 diff --git a/mayor-orig/mayor-base/www/include/base/config.php b/mayor-orig/mayor-base/www/include/base/config.php index 28f711cb..8ac2614c 100644 --- a/mayor-orig/mayor-base/www/include/base/config.php +++ b/mayor-orig/mayor-base/www/include/base/config.php @@ -4,8 +4,6 @@ if (PHP_SAPI!=='cli') define('_RUNLEVEL','www'); else define('_RUNLEVEL','cron') define('_JSLIB','jquery.min'); -if (!defined('_LOGLEVEL')) define('_LOGLEVEL',10); - date_default_timezone_set('Europe/Budapest'); if (_RUNLEVEL === 'cron') { @@ -26,6 +24,9 @@ if (_RUNLEVEL === 'cron') { } } +if (!defined('_LOGLEVEL')) define('_LOGLEVEL',10); +if (!defined('__DEBUG')) define('__DEBUG',false); + if (!defined('_SECURECOOKIE')) define('_SECURECOOKIE', true); define('_BASE_URL',( ($_SERVER['HTTPS']=='on')?"https://".$_SERVER['SERVER_NAME']:"http://".$_SERVER['SERVER_NAME'] )); diff --git a/mayor-orig/mayor-base/www/include/base/log.php b/mayor-orig/mayor-base/www/include/base/log.php index 14e214a9..4ea4f4f7 100644 --- a/mayor-orig/mayor-base/www/include/base/log.php +++ b/mayor-orig/mayor-base/www/include/base/log.php @@ -27,6 +27,9 @@ $msg = date('Y-m-d H:i:s').' '.$userAccount.': '.$message."\n"; fputs($fp,$msg); fclose($fp); + } else { + echo 'fatal error 004'; + die(); } } } diff --git a/mayor-orig/mayor-base/www/include/base/mysql.php b/mayor-orig/mayor-base/www/include/base/mysql.php index e5e4a2e3..12aeb771 100644 --- a/mayor-orig/mayor-base/www/include/base/mysql.php +++ b/mayor-orig/mayor-base/www/include/base/mysql.php @@ -196,9 +196,11 @@ if (MYSQLI_ENABLED===true) { $r = mysqli_query($lr,$q); $_insert_id = mysqli_insert_id($lr); // itt lekérdezzük, hogy a warning lekérdezés ne rontsa el debug=true esetén!! + $_affected_rows = mysqli_affected_rows($lr); } else { $r = @mysql_query($q, $lr); $_insert_id = mysql_insert_id($lr); + $_affected_rows = mysql_affected_rows($lr); } define(MYSQL_LOGGER,false); if (MYSQL_LOGGER === true) { @@ -289,7 +291,7 @@ $RESULT = $_insert_id; // mysqli_insert_id($lr); - ez itt már elromlik debug=true esetén a warning lekérdezés miatt mayorLogger(1,'mysql',$q,_USERACCOUNT); } elseif ($SET['result'] == 'affected rows') { - $RESULT = mysqli_affected_rows($lr); + $RESULT = $_affected_rows; // $RESULT = mysqli_affected_rows($lr); mayorLogger(1,'mysql',$q,_USERACCOUNT); } else { // create, insert, de nem olyan resulttal... $RESULT = $r; @@ -333,7 +335,7 @@ $RESULT = $_insert_id; // mysql_insert_id($lr); - ez itt már elromlik debug=true esetén a warning lekérdezés miatt mayorLogger(1,'mysql',$q,_USERACCOUNT); } elseif ($SET['result'] == 'affected rows') { - $RESULT = mysql_affected_rows($lr); + $RESULT = $_affected_rows; // $RESULT = mysql_affected_rows($lr); mayorLogger(1,'mysql',$q,_USERACCOUNT); } else { // create, insert, de nem olyan resulttal... $RESULT = $r; |