* This script gathers system specification details for use with bug reporting
* and anyone else who needs it.
*
- * @copyright © 1999-2006 The SquirrelMail Project Team
+ * @copyright © 1999-2007 The SquirrelMail Project Team
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
* @version $Id$
* @package plugins
/**
* do not allow to call this file directly
*/
-if ((isset($_SERVER) && $_SERVER['SCRIPT_FILENAME'] == __FILE__) ||
- (isset($HTTP_SERVER_SERVER) && $HTTP_SERVER_SERVER['SCRIPT_FILENAME'] == __FILE__) ) {
+if ((isset($_SERVER['SCRIPT_FILENAME']) && $_SERVER['SCRIPT_FILENAME'] == __FILE__) ||
+ (isset($HTTP_SERVER_SERVER['SCRIPT_FILENAME']) && $HTTP_SERVER_SERVER['SCRIPT_FILENAME'] == __FILE__) ) {
header("Location: ../../src/login.php");
die();
}
if ($key != 0 || $value != '') {
$str .= " * $key = $value";
// add plugin version
- if (function_exists($value . '_version')) {
+ $version_found = FALSE;
+ if (function_exists($value . '_info')) {
+ $info = call_user_func($value . '_info');
+ if (!empty($info['version'])) {
+ $str .= ' ' . $info['version'];
+ $version_found = TRUE;
+ }
+ }
+ if (!$version_found && function_exists($value . '_version')) {
$str.= ' ' . call_user_func($value . '_version');
}
$str.="\n";
&& ! in_array('compatibility',$plugins)) {
$str.= ' * compatibility';
include_once(SM_PATH . 'plugins/compatibility/setup.php');
- if (function_exists('compatibility_version')) {
- $str.= ' ' . call_user_func('compatibility_version');
+ $version_found = FALSE;
+ if (function_exists('compatibility_info')) {
+ $info = compatibility_info();
+ if (!empty($info['version'])) {
+ $str .= ' ' . $info['version'];
+ $version_found = TRUE;
+ }
+ }
+ if (!$version_found && function_exists('compatibility_version')) {
+ $str.= ' ' . compatibility_version();
}
$str.="\n";
}
}
$body = htmlspecialchars($body_top . $body);
-
-?>
\ No newline at end of file