Use require instead of require_once on require.php

This commit is contained in:
markjcrane 2023-06-17 09:11:32 -06:00
parent d6cb17e5b9
commit c92872ab8f
1 changed files with 17 additions and 17 deletions

View File

@ -37,15 +37,15 @@ if (!class_exists('schema')) {
//class constructor //class constructor
public function __construct() { public function __construct() {
//includes files
require dirname(__DIR__, 2) . "/resources/require.php";
//connect to the database //connect to the database
require_once "resources/classes/database.php";
$database = new database; $database = new database;
$database->connect(); $database->connect();
$this->db = $database->db; $this->db = $database->db;
//includes files
require_once dirname(__DIR__, 2) . "/resources/require.php";
//get the list of installed apps from the core and mod directories //get the list of installed apps from the core and mod directories
$config_list = glob($_SERVER["DOCUMENT_ROOT"] . PROJECT_PATH . "/*/*/app_config.php"); $config_list = glob($_SERVER["DOCUMENT_ROOT"] . PROJECT_PATH . "/*/*/app_config.php");
$x=0; $x=0;
@ -474,21 +474,21 @@ if (!class_exists('schema')) {
if ($format == '') $format = $output_format; if ($format == '') $format = $output_format;
//get the db variables //get the db variables
require_once "resources/classes/config.php"; //require_once "resources/classes/config.php";
$config = new config; //$config = new config;
$config_exists = $config->exists(); //$config_exists = $config->exists();
$config_path = $config->find(); //$config_path = $config->find();
$config->get(); //$config->get();
$db_type = $config->db_type; //$db_type = $config->db_type;
$db_name = $config->db_name; //$db_name = $config->db_name;
$db_username = $config->db_username; //$db_username = $config->db_username;
$db_password = $config->db_password; //$db_password = $config->db_password;
$db_host = $config->db_host; //$db_host = $config->db_host;
$db_path = $config->db_path; //$db_path = $config->db_path;
$db_port = $config->db_port; //$db_port = $config->db_port;
//includes files //includes files
require_once dirname(__DIR__, 2) . "/resources/require.php"; require dirname(__DIR__, 2) . "/resources/require.php";
//add multi-lingual support //add multi-lingual support
if (!isset($text)) { if (!isset($text)) {