* @return string $header
*/
function prepareRFC822_Header($rfc822_header, $reply_rfc822_header, &$raw_length) {
- global $domain, $version, $username, $encode_header_key,
+ global $domain, $username, $encode_header_key,
$edit_identity, $hide_auth_header;
/* if server var SERVER_NAME not available, use $domain */
}
}
/* Identify SquirrelMail */
- $header[] = 'User-Agent: SquirrelMail/' . $version . $rn;
+ $header[] = 'User-Agent: SquirrelMail/' . SM_VERSION . $rn;
/* Do the MIME-stuff */
$header[] = 'MIME-Version: 1.0' . $rn;
$contenttype = 'Content-Type: '. $rfc822_header->content_type->type0 .'/'.
print CF " * Created using the configure script, conf.pl\n";
print CF " */\n";
print CF "\n";
- print CF "global \$version;\n";
if ($print_config_version) {
print CF "\$config_version = '$print_config_version';\n";
*/
/* Do not change this value. */
-global $version;
global $config_version;
$config_version = '1.5.0';
/** @ignore */
+/**
+ * SquirrelMail version number -- DO NOT CHANGE
+ * @since 1.5.2
+ */
+define('SM_VERSION', '1.5.2 [SVN]');
+
/**************************************************************/
/* Set values for constants used by SquirrelMail preferences. */
/**************************************************************/
session_set_cookie_params (0, $base_uri);
sqsession_is_active();
-/**
- * SquirrelMail version number -- DO NOT CHANGE
- */
-$version = '1.5.2 [SVN]';
-
/**
* SquirrelMail internal version number -- DO NOT CHANGE
* $sm_internal_version = array (release, major, minor)
*/
-$SQM_INTERNAL_VERSION = array(1,5,2);
+$SQM_INTERNAL_VERSION = preg_split('/\./', SM_VERSION, 3);
+$SQM_INTERNAL_VERSION[2] = intval($SQM_INTERNAL_VERSION[2]);
/* if plugins are disabled only for one user and
return $ret;
}
-global $languages, $version;
+global $languages;
$language_values = array( );
foreach ($languages as $lang_key => $lang_attributes) {
'size' => 7 ),
'SM_ver' => array( 'name' => _("SquirrelMail Version"),
'type' => SMOPT_TYPE_EXTERNAL,
- 'value' => "$version" ),
+ 'value' => SM_VERSION ),
'PHP_ver' => array( 'name' => _("PHP Version"),
'type' => SMOPT_TYPE_EXTERNAL,
'value' => phpversion() ),
" * SquirrelMail Configuration File\n".
" * Created using the Administrator Plugin\n".
" */\n".
- "\n".
- "global \$version;\n" );
+ "\n" );
foreach ( $newcfg as $k => $v ) {
if ( $k{0} == '$' && $v <> '' || is_int($v)) {
alt="SquirrelMail Logo" /><br />
<table align="center" width="80%" cellpadding="1" cellspacing="2" border="0">
<tr><td bgcolor="#dcdcdc" align="center"><div style="text-align: center;"><b>
-<?php echo sprintf(_("About SquirrelMail %s"),$version); ?>
+<?php echo sprintf(_("About SquirrelMail %s"), SM_VERSION); ?>
</b></div></td></tr>
<tr><td>
<br />
</b><br/><br/>
<small>
<?php
-echo sprintf(_("You are using SquirrelMail version: %s"),$version);
+echo sprintf(_("You are using SquirrelMail version: %s"), SM_VERSION);
echo "<br />\n";
echo _("The administrator installed the following plugins:");
echo "<br />\n";
/** @ignore */
define('SM_PATH', '../');
/** load minimal function set */
+require(SM_PATH . 'include/constants.php');
require(SM_PATH . 'functions/global.php');
require(SM_PATH . 'functions/strings.php');
+$SQM_INTERNAL_VERSION = preg_split('/\./', SM_VERSION, 3);
+$SQM_INTERNAL_VERSION[2] = intval($SQM_INTERNAL_VERSION[2]);
/** set default value in order to block remote access */
$allow_remote_configtest=false;
}
/* checking PHP specs */
-echo "<p><table>\n<tr><td>SquirrelMail version:</td><td><b>" . $version . "</b></td></tr>\n" .
+echo "<p><table>\n<tr><td>SquirrelMail version:</td><td><b>" . SM_VERSION . "</b></td></tr>\n" .
'<tr><td>Config file version:</td><td><b>' . $config_version . "</b></td></tr>\n" .
'<tr><td>Config file last modified:</td><td><b>' .
date ('d F Y H:i:s', filemtime(SM_PATH . 'config/config.php')) .
function SendMDN ( $mailbox, $passed_id, $sender, $message, $imapConnection) {
global $username, $attachment_dir, $popuser, $username, $color,
- $version, $squirrelmail_language, $default_charset,
+ $squirrelmail_language, $default_charset,
$languages, $useSendmail, $domain, $sent_folder;
sqgetGlobalVar('SERVER_NAME', $SERVER_NAME, SQ_SERVER);
$original_recipient = $to;
$original_message_id = $header->message_id;
- $report = "Reporting-UA : $SERVER_NAME ; SquirrelMail (version $version) \r\n";
+ $report = "Reporting-UA : $SERVER_NAME ; SquirrelMail (version " . SM_VERSION . ") \r\n";
if ($original_recipient != '') {
$report .= "Original-Recipient : $original_recipient\r\n";
}