<?php
-
/**
- * This gathers system specification details for use with bug reporting
+ * This script gathers system specification details for use with bug reporting
* and anyone else who needs it.
*
- * This is a standard SquirrelMail 1.2 API for plugins.
- *
- * @copyright © 1999-2005 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
* @subpackage bug_report
*/
-/** @ignore */
-if (!defined('SM_PATH')) define('SM_PATH','../../');
+/**
+ * do not allow to call this file directly
+ */
+if (isset($_SERVER['SCRIPT_FILENAME']) && $_SERVER['SCRIPT_FILENAME'] == __FILE__) {
+ header("Location: ../../src/login.php");
+ die();
+}
/**
* load required libraries
*/
-include_once(SM_PATH . 'include/validate.php');
-include_once(SM_PATH . 'functions/imap.php');
-global $body, $username;
+include_once(SM_PATH . 'functions/imap_general.php');
+
/**
if (is_array($plugins) && $plugins!=array()) {
foreach ($plugins as $key => $value) {
if ($key != 0 || $value != '') {
- $str .= " * $key = $value";
- // add plugin version
- if (function_exists($value . '_version')) {
- $str.= ' ' . call_user_func($value . '_version');
- }
- $str.="\n";
+ $str .= " * $key = $value " . get_plugin_version($value, TRUE) . "\n";
}
}
- // compatibility plugin can be used without need to enable it in sm config
+ // compatibility plugin can be used without needing to enable it in sm config
if (file_exists(SM_PATH . 'plugins/compatibility/setup.php')
&& ! 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');
- }
- $str.="\n";
+ $str.= ' * compatibility ' . get_plugin_version('compatibility', TRUE) . "\n";
}
}
if ($str == '') {
}
$body = htmlspecialchars($body_top . $body);
-
-?>
\ No newline at end of file