#327 Fix query, use DB settings on index page
This commit is contained in:
parent
4934c60e34
commit
6d9362ed4d
@ -1988,7 +1988,7 @@ function mfh_getSettings() {
|
||||
global $hesk_settings;
|
||||
|
||||
$settings = array();
|
||||
$res = hesk_dbQuery("SELECT `Key`, `Value` FROM `".hesk_dbEscape($hesk_settings['db_pfix'])."settings` WHERE `Key` <> 'version'");
|
||||
$res = hesk_dbQuery("SELECT `Key`, `Value` FROM `".hesk_dbEscape($hesk_settings['db_pfix'])."settings` WHERE `Key` <> 'modsForHeskVersion'");
|
||||
while ($row = hesk_dbFetchAssoc($res)) {
|
||||
$settings[$row['Key']] = $row['Value'];
|
||||
}
|
||||
|
@ -34,7 +34,11 @@
|
||||
|
||||
/* Check if this is a valid include */
|
||||
if (!defined('IN_SCRIPT')) {die('Invalid attempt');}
|
||||
require(HESK_PATH . 'modsForHesk_settings.inc.php');
|
||||
if (!function_exists('mfh_getSettings')) {
|
||||
die('Mods for HESK settings are not accessible!');
|
||||
}
|
||||
|
||||
$modsForHesk_settings = mfh_getSettings();
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
|
@ -38,12 +38,12 @@ define('WYSIWYG',1);
|
||||
|
||||
// Get all the required files and functions
|
||||
require(HESK_PATH . 'hesk_settings.inc.php');
|
||||
require(HESK_PATH . 'modsForHesk_settings.inc.php');
|
||||
require(HESK_PATH . 'inc/common.inc.php');
|
||||
|
||||
hesk_load_database_functions();
|
||||
hesk_dbConnect();
|
||||
// Are we in maintenance mode?
|
||||
hesk_check_maintenance();
|
||||
hesk_load_database_functions();
|
||||
|
||||
// Are we in "Knowledgebase only" mode?
|
||||
hesk_check_kb_only();
|
||||
|
Loading…
x
Reference in New Issue
Block a user