26 require
'../../main.inc.php';
28 $langs->load(
"admin");
38 $form =
new Form($db);
45 print '<div class="div-table-responsive-no-min">';
46 print
'<table class="noborder centpercent">';
47 print
'<tr class="liste_titre"><td colspan="2">'.$langs->trans(
"Database").
'</td></tr>'.
"\n";
48 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"Version").
'</td><td>'.$db::LABEL.
' '.$db->getVersion().
'</td></tr>'.
"\n";
49 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DatabaseServer").
'</td><td>'.$conf->db->host.
'</td></tr>'.
"\n";
50 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DatabasePort").
'</td><td>'.(empty($conf->db->port) ? $langs->trans(
"Default") : $conf->db->port).
'</td></tr>'.
"\n";
51 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DatabaseName").
'</td><td>'.$conf->db->name.
'</td></tr>'.
"\n";
52 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DriverType").
'</td><td>'.$conf->db->type.($db->getDriverInfo() ?
' ('.$db->getDriverInfo().
')' :
'').
'</td></tr>'.
"\n";
53 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"User").
'</td><td>'.$conf->db->user.
'</td></tr>'.
"\n";
54 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"Password").
'</td><td>'.preg_replace(
'/./i',
'*', $dolibarr_main_db_pass).
'</td></tr>'.
"\n";
55 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DBStoringCharset").
'</td><td>'.$db->getDefaultCharacterSetDatabase().
'</td></tr>'.
"\n";
56 print
'<tr class="oddeven"><td width="300">'.$langs->trans(
"DBSortingCharset").
'</td><td>'.$db->getDefaultCollationDatabase().
'</td></tr>'.
"\n";
62 print
'<div class="div-table-responsive-no-min">';
63 print
'<table class="noborder centpercent">';
64 print
'<tr class="liste_titre"><td colspan="2">'.$langs->trans(
"Tables").
'</td></tr>'.
"\n";
65 print
'<tr class="oddeven"><td width="300"><a href="'.DOL_URL_ROOT.
'/admin/system/database-tables.php?mainmenu=home">'.$langs->trans(
"List").
'</a></td></tr>'.
"\n";
69 $listofvars = $db->getServerParametersValues();
70 $listofstatus = $db->getServerStatusValues();
71 $arraylist = array(
'listofvars',
'listofstatus');
73 if (!count($listofvars) && !count($listofstatus))
75 print $langs->trans(
"FeatureNotAvailableWithThisDatabaseDriver");
77 foreach ($arraylist as $listname)
80 print
'<div class="div-table-responsive-no-min">';
81 print
'<table class="noborder centpercent">';
82 print
'<tr class="liste_titre">';
83 print
'<td width="300">'.$langs->trans(
"Parameters").
'</td>';
84 print
'<td>'.$langs->trans(
"Value").
'</td>';
89 if (preg_match(
'/mysql/i', $db->type))
92 'character_set_database'=>array(
'var'=>
'dolibarr_main_db_character_set',
'valifempty'=>
'utf8'),
93 'collation_database'=>array(
'var'=>
'dolibarr_main_db_collation',
'valifempty'=>
'utf8_unicode_ci')
98 if ($listname ==
'listofvars') $listtouse = $listofvars;
99 if ($listname ==
'listofstatus') $listtouse = $listofstatus;
101 foreach ($listtouse as $param => $paramval)
103 print
'<tr class="oddeven">';
107 print
'<td class="wordbreak">';
108 $show = 0; $text =
'';
109 foreach ($arraytest as $key => $val)
111 if ($key != $param)
continue;
112 $val2 = ${$val[
'var']};
113 $text =
'Should be in line with value of param <b>'.$val[
'var'].
'</b> thas is <b>'.($val2 ? $val2 :
"'' (=".$val[
'valifempty'].
")").
'</b>';
116 if ($show == 0) print $paramval;
117 if ($show == 1) print $form->textwithpicto($paramval, $text);
118 if ($show == 2) print $form->textwithpicto($paramval, $text, 1,
'warning');
122 print
'</table>'.
"\n";
load_fiche_titre($titre, $morehtmlright= '', $picto= 'generic', $pictoisfullpath=0, $id= '', $morecssontable= '', $morehtmlcenter= '')
Load a title with picto.
accessforbidden($message= '', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program Calling this function terminate execution ...
print
Draft customers invoices.