| 1 |
<?php |
<?php |
| 2 |
|
|
| 3 |
// $Id: reroute_email.module,v 1.1.2.3 2007/08/01 01:04:53 kbahey Exp $ |
// $Id: reroute_email.module,v 1.1.2.4 2007/08/21 18:42:01 kbahey Exp $ |
| 4 |
|
|
| 5 |
define('REROUTE_EMAIL_ADDRESS', 'reroute_email_address'); |
define('REROUTE_EMAIL_ADDRESS', 'reroute_email_address'); |
| 6 |
|
|
| 37 |
function reroute_email_mail_alter(&$mailkey, &$to, &$subject, &$body, &$from, &$headers) { |
function reroute_email_mail_alter(&$mailkey, &$to, &$subject, &$body, &$from, &$headers) { |
| 38 |
global $base_url; |
global $base_url; |
| 39 |
|
|
| 40 |
|
// Suppress Bcc and Cc fields otherwise email will still go out to those addresses |
| 41 |
|
unset($headers['Bcc']); |
| 42 |
|
unset($headers['Cc']); |
| 43 |
|
|
| 44 |
// Format a message to show at the top |
// Format a message to show at the top |
| 45 |
$msg = "This email was rerouted.\n"; |
$msg = "This email was rerouted.\n"; |
| 46 |
$msg .= "Web site: @site\n"; |
$msg .= "Web site: @site\n"; |