Ted Roche
Forum Replies Created
-
after the line
function hr_rotate(){
change
require (ABSPATH.'/wp-admin/custom-header.php');
to
require_once (ABSPATH.'/wp-admin/custom-header.php');Confirmed! That fixes it. Thanks!
Forum: Everything else WordPress
In reply to: Admin email helpThere’s a couple conflicting things going on here. First, wp_mail explicitly hardcodes ‘wordpress’ @ yourservername.tld in the _header_ of the email, that’s the outside envelope, but not necessarily what the recipient will see.
function wp_mail($to, $subject, $message, $headers = ”) {
if( $headers == ” ) {
$headers = “MIME-Version: 1.0\n” .
“From: ” . get_settings(‘admin_email’) . “\n” .
“Content-Type: text/plain; charset=\”” . get_settings(‘blog_charset’) . “\”\n”;
# was: “From: wordpress@” . preg_replace(‘#^www\.#’, ”, strtolower($_SERVER[‘SERVER_NAME’])) . “\n” .
}return @mail($to, $subject, $message, $headers);
}The second problem is PHP’s tendency to send mail with a “Return-Path” setting of ‘[email protected]’ or whatever the name of your name server is. You can fix that with the fix described here:
http://drupal.org/project/returnpath
You might be able to override this for multiple named-hosts on a server with php_value settings for each host configuration file, but I haven’t tried that.
There’s a good chance that all of this will be moot if you upgrade to the 2.2 version.