* Mon May 12 2025 Brian Read <brianr@koozali.org> 11.0.0-1.sme

- Adding SM2 panel [SME: 13004]
- Upgrade to phpsysinfo 3.4.4
- Add code to delete inline styles and add css to make it look better.
- version saved / built uses the static version, which means no drops downs and choices.
This commit is contained in:
2025-05-14 16:14:01 +01:00
parent 80b1da5fa5
commit c8ce77259d
952 changed files with 51341 additions and 28699 deletions

View File

@@ -1,6 +1,6 @@
<?php
/**
* Error class
* PSI_Error class
*
* PHP version 5
*
@@ -8,7 +8,7 @@
* @package PSI_Error
* @author Michael Cramer <BigMichi1@users.sourceforge.net>
* @copyright 2009 phpSysInfo
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License version 2, or (at your option) any later version
* @version SVN: $Id: class.Error.inc.php 569 2012-04-16 06:08:18Z namiltd $
* @link http://phpsysinfo.sourceforge.net
*/
@@ -19,17 +19,17 @@
* @package PSI_Error
* @author Michael Cramer <BigMichi1@users.sourceforge.net>
* @copyright 2009 phpSysInfo
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License version 2, or (at your option) any later version
* @version Release: 3.0
* @link http://phpsysinfo.sourceforge.net
*/
class Error
class PSI_Error
{
/**
* holds the instance of this class
*
* @static
* @var object
* @var PSI_Error
*/
private static $_instance;
@@ -59,7 +59,7 @@ class Error
/**
* Singleton function
*
* @return Error instance of the class
* @return PSI_Error instance of the class
*/
public static function singleton()
{
@@ -113,8 +113,8 @@ class Error
/**
* add a config error to the internal list
*
* @param object $strCommand Command, which cause the Error
* @param object $strMessage additional Message, to describe the Error
* @param string $strCommand Command, which cause the Error
* @param string $strMessage additional Message, to describe the Error
*
* @return void
*/
@@ -126,8 +126,8 @@ class Error
/**
* add a php error to the internal list
*
* @param object $strCommand Command, which cause the Error
* @param object $strMessage additional Message, to describe the Error
* @param string $strCommand Command, which cause the Error
* @param string $strMessage additional Message, to describe the Error
*
* @return void
*/
@@ -171,8 +171,8 @@ class Error
$error->addAttribute('Message', $arrLine['message']);
$error->addAttribute('Function', $arrLine['command']);
}
header("Cache-Control: no-cache, must-revalidate\n");
header("Content-Type: text/xml\n\n");
header('Cache-Control: no-cache, must-revalidate');
header('Content-Type: text/xml');
echo $xml->getSimpleXmlElement()->asXML();
exit();
}
@@ -229,7 +229,9 @@ class Error
if ($val == $arrTrace[count($arrTrace) - 1]) {
break;
}
$strBacktrace .= str_replace(APP_ROOT, ".", $val['file']).' on line '.$val['line'];
if (isset($val['file'])) {
$strBacktrace .= str_replace(PSI_APP_ROOT, ".", $val['file']).' on line '.$val['line'];
}
if ($strFunc) {
$strBacktrace .= ' in function '.$strFunc;
}
@@ -238,10 +240,14 @@ class Error
} else {
$strFunc = $val['function'].'(';
if (isset($val['args'][0])) {
if (($val['function'] == 'executeProgram') && ($val['args'][0] == 'sshpass')
&& isset($val['args'][1]) && preg_match('/"([^"]+)"$/', $val['args'][1], $tmpout)) {
$val['args'][1] = 'ssh: '. $tmpout[1];
}
$strFunc .= ' ';
$strComma = '';
foreach ($val['args'] as $val) {
$strFunc .= $strComma.$this->_printVar($val);
foreach ($val['args'] as $valArgs) {
$strFunc .= $strComma.$this->_printVar($valArgs);
$strComma = ', ';
}
$strFunc .= ' ';