The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.2.25 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/printthread.php 16 require_once



UserSpice
change database name - Printable Version

+- UserSpice (https://userspice.com/forums)
+-- Forum: Support Center (https://userspice.com/forums/forumdisplay.php?fid=23)
+--- Forum: UserSpice 4.3 and Below (https://userspice.com/forums/forumdisplay.php?fid=26)
+--- Thread: change database name (/showthread.php?tid=1124)



change database name - weetax - 08-27-2018

How to change the database name after install successfully. Where the path to specify the database name?


RE: change database name - Brandin - 08-27-2018

users/init.php.


RE: change database name - weetax - 08-27-2018

<?php
require_once 'classes/class.autoloader.php';
session_start();

$abs_us_root=$_SERVER['DOCUMENT_ROOT'];

$self_path=explode("/", $_SERVER['PHP_SELF']);
$self_path_length=count($self_path);
$file_found=FALSE;

for($i = 1; $i < $self_path_length; $i++){
array_splice($self_path, $self_path_length-$i, $i);
$us_url_root=implode("/",$self_path)."/";

if (file_exists($abs_us_root.$us_url_root.'z_us_root.php')){
$file_found=TRUE;
break;
}else{
$file_found=FALSE;
}
}

require_once $abs_us_root.$us_url_root.'users/helpers/helpers.php';

// Set config
$GLOBALS['config'] = array(
'mysql'      => array(

Add some config to

$GLOBALS['config'] = array(
'mysql' => array(

'host' => '192.168.xxx.xxx',
'username' => 'xxxxx',
'password' => 'xxxxx',
'db' => 'S2SDB_DEV1',
),


RE: change database name - Brandin - 08-29-2018

Do you still require help? That is the file you make the modification in.