<configtab name="compose" desc="Compose">
<configsection name="msg">
- <configboolean name="prepend_header" desc="Should we include the contents of
- imp/config/header.php in the headers of every message
- sent?">true</configboolean>
<configboolean name="append_trailer" desc="Should we append the contents of
imp/config/trailer.txt to the end of every message
sent?">true</configboolean>
+++ /dev/null
-<?php
-/**
- * This file will allow you to set headers to append to outgoing mail messages.
- *
- * To add a new header item, simply add a new entry to the $_header array.
- * KEY: Header name (must be in US-ASCII charset))
- * VALUE: Header data (must be in US-ASCII charset)
- *
- * $Id$
- */
-
-$_header = array(
-
- // Add information on organization to which the sender belongs.
- // Not standardized for use in e-mail, but generally recognized.
- // See RFC 2076 [3.7]; RFC 1036 [2.2.8]
- //'Organization' => 'Example Corp.',
-
- // Add the IP of the remote browser
- //'X-Originating-IP' => $_SERVER['REMOTE_ADDR'],
-
- // Add the Browser information of the remote browser
- //'X-Remote-Browser' => $_SERVER['HTTP_USER_AGENT'],
-
-);
*/
// public function pre_sent($message, $headers)
// {
-// // Do action here -- no return value from this hook.
+// // Example: Add custom headers to outgoing message.
+// $charset = $GLOBALS['registry']->getCharset();
+// $custom_hdrs = array();
+// $hdr_charset = $message->getHeaderCharset();
+//
+// /* Add information on organization to which the sender belongs.
+// * Not standardized for use in e-mail, but generally recognized.
+// * See RFC 2076 [3.7]; RFC 1036 [2.2.8] */
+// $custom_hdrs['Organization'] = 'Example Corp.';
+//
+// // Add the IP of the remote browser
+// $custom_hdrs['X-Originating-IP'] = $_SERVER['REMOTE_ADDR'];
+//
+// // Add the Browser information of the remote browser
+// $custom_hdrs['X-Remote-Browser'] = $_SERVER['HTTP_USER_AGENT'];
+//
+// foreach ($custom_hdrs as $key => $val) {
+// $headers->addHeader($key, Horde_String::convertCharset($val, $charset, $hdr_charset));
+// }
// }
The 'max_from_chars' and 'max_subj_chars' configuration options for the
minimal (mimp) display have been removed.
-The 'cache_folders', 'limit_factor', and 'sort_limit' configuration options
-have been removed.
+The 'cache_folders', 'limit_factor', 'prepend_header', and 'sort_limit'
+configuration options have been removed.
Preferences
* x-priority now handled in the core code
* old attachment icon handling see atc_flag pref
* msglist_flags hook now used to dynamically set flags on messages
+* The headers.php configuration file has been removed; setting custom headers
+ is now done via the 'pre_sent' hook.
Fetchmail
}
$headers->addUserAgentHeader();
- /* Tack on any site-specific headers. */
- try {
- $headers_result = Horde::loadConfiguration('header.php', '_header');
- if (is_array($headers_result)) {
- foreach ($headers_result as $key => $val) {
- $headers->addHeader(trim($key), Horde_String::convertCharset(trim($val), $GLOBALS['registry']->getCharset(), $charset));
- }
- }
- } catch (Horde_Exception $e) {}
-
- $sentmail = $GLOBALS['injector']->getInstance('IMP_Sentmail');
-
/* Send the messages out now. */
if (!($reply_type = $this->getMetadata('reply_type'))) {
$reply_type = 'new';
}
+ $sentmail = $GLOBALS['injector']->getInstance('IMP_Sentmail');
+
foreach ($send_msgs as $val) {
try {
$this->sendMessage($val['to'], $headers, $val['msg']);