From d5d03875f0dd6c46634484e4b71543c6b028c036 Mon Sep 17 00:00:00 2001 From: Ibnu Maksum Date: Wed, 24 Jul 2024 09:20:21 +0700 Subject: [PATCH] fix installation --- init.php | 7 +++- install/step4.php | 81 +++++++++++++++++++++++------------------------ 2 files changed, 46 insertions(+), 42 deletions(-) diff --git a/init.php b/init.php index 16e7bd3..baf747b 100644 --- a/init.php +++ b/init.php @@ -67,9 +67,13 @@ require_once $root_path . File::pathFixer('system/orm.php'); require_once $root_path . File::pathFixer('system/autoload/PEAR2/Autoload.php'); include $root_path . File::pathFixer('system/autoload/Hookers.php'); +if(!empty($db_password)){ + // compability for old version + $db_pass = $db_password; +} ORM::configure("mysql:host=$db_host;dbname=$db_name"); ORM::configure('username', $db_user); -ORM::configure('password', $db_password); +ORM::configure('password', $db_pass); ORM::configure('return_result_sets', true); if ($_app_stage != 'Live') { ORM::configure('logging', true); @@ -112,6 +116,7 @@ date_default_timezone_set($config['timezone']); if ((!empty($radius_user) && $config['radius_enable']) || _post('radius_enable')) { if(!empty($radius_password)){ + // compability for old version $radius_pass = $radius_password; } ORM::configure("mysql:host=$radius_host;dbname=$radius_name", null, 'radius'); diff --git a/install/step4.php b/install/step4.php index c7b3040..751c571 100644 --- a/install/step4.php +++ b/install/step4.php @@ -28,61 +28,60 @@ if ($cn == '1') { if (isset($_POST['radius']) && $_POST['radius'] == 'yes') { $input = '