View Full Version : "Sender" shows box address
myplaces
01-27-2009, 12:43 PM
I have link catalog on my website. When someone ad link, he gets mail where sender is mydomain@box457.bluehost.com
What i need to do to change sender - myname@mydomain.com?
felgall
01-27-2009, 04:50 PM
I have link catalog on my website. When someone ad link, he gets mail where sender is mydomain@box457.bluehost.com
What i need to do to change sender - myname@mydomain.com?
Create the myname@mydomain.com email account so that the sender address exists.
thomasw98
02-04-2009, 09:09 PM
Create the myname@mydomain.com email account so that the sender address exists.
I have the same problem. Doing what you said does not make any difference. There are several other threads that also mention this same issue and also have the same advice and also the end result is no improvement.
Is there any OTHER ideas how to solve this?
For me, it is even worse, since I need the sender address to be sender@mysubdomain.com whereas what I am getting now is mainloginname@box194.bluehost.com. My users are really confused when they see this mainloginname (a shortened version of my main domain name) since it has nothing to do with my subdomain. The box194.bluehost.com also really confuses them.
felgall
02-04-2009, 11:41 PM
I have never had any problem with sending email from any email address that either exists as an account, has a redirect set up to an account, or is on a domain not hosted on BlueHost.
The only thing I can think of as to why others have problems with it is if they don't have the account or redirect set up correctly and the only people who can check that for you are BlueHost support.
thomasw98
02-04-2009, 11:54 PM
A few minutes ago, I installed a plugin called wp-mail-smtp in wordpress and it seems to have partially solved the problem. So now the sender address shows as whatever I want it to be. But message headers are still filled with mainloginname@box194.bluehost.com references. If any recipient of this email looks into the headers, they will see this stuff, whereas I would prefer they not know anything about bluehost or my mainloginname.
Anyways, a partial solution is better than nothing i guess.
For the record, from my research, this seems to definitely be a bluehost specific problem. The wordpress forums are filled with posts about this same problem (always related to wordpress on bluehost) but nobody over there has a full solution either. I wish bluehost would address the issue instead of telling everybody to contact wordpress. This problem exists only on bluehost servers, so obviously it is not a wordpress problem.
thomasw98
02-05-2009, 01:07 AM
I use wp with bluehost but I don't have this problem, so maybe there's a particular setup you are doing wrong, I've been using it since wp 2.3 http://www.image-jump.com/image/Q/8.gif
Yeah, I think you are right. My particular case is that my current focus website is a subdomain under bluehost, but the email headers are showing info about the main domain login name plus the bluehost box garbage. i think it may be happening because of the subdomain issue. I never had this problem in the past either and I have used Wordpress for many years also.
felgall
02-05-2009, 10:08 AM
There is no difference between a somain and a sub-domain so the problem must be elsewhere.
thomasw98
02-06-2009, 12:00 PM
Are you sure that once you made the email it is on the subdomain? Not the main domain? Just checkinghttp://www.image-jump.com/image/Q/8.gif
Yeah, that's what I did.
Wordpress is installed on subdomain.com
My wordpress admin email is fake@subdomain.com
My wordpress admin name is Fake
The subdomain is subdomain.com
The subdomain has as email account setup for fake@subdomain.com
The main domain is maindomain.com
The main domain login is maindoma
When wordpress sends out email to customers (such as for new user signups, etc), the "sent from" name is "Fake", so that's ok. But if the email recipient looks in the message headers, he will see the message is from "maindoma@box194.bluehost.com" with "Return to" shown as "fake@subdomain.com".
This is bad because "maindoma" gives a hint to the maindomain name. And of course, this maindomain has nothing to do with the subdomain. Completely different topic and users. Also showing "bluehost.com" is not my preference either. Love "the blue" and have used them for 5+ years, but I don't think I need to show this relationship to my users in my message headers.
When wordpress sends out email to admin, it is even worse. The "sent from" is "maindoma@box194.bluehost.com". Message headers also filled with the same "maindoma@box194.bluehost.com" references.
Actually, I don't really care about these emails to admin (since that is me). But it is a little annoying still. I fixed this problem by using a plugin (see earlier post), but the message headers for both user emails and admin emails still show "maindoma@box194.bluehost.com".
agathoune
03-12-2009, 05:08 PM
I'm getting the same issue. That's at least 3 of us now (and more on other wordpress forums who use bluehost). When Wordpress sends out emails like password resets, comments notifications, etc. it resolves my email address XX@domain.com into domain@box464.bluehost.com
This seems like some sort of registered domain name/local domain name resolution issue. Basically, for admin generated emails the bluehost server seems to restamp them with the local bluehost domain.
Here are 2 other topic posts on wordpress.org of bluehost users with this issue:
http://wordpress.org/support/topic/238357
http://wordpress.org/support/topic/235626
Anyone looking into this or is it just being swept under the rug as a "wordpress" issue?
felgall
03-12-2009, 05:48 PM
As long as the sending email addresses are real email accounts or areforwarders to a real email account then that email address will be used. If you try to send from an email address that doesn't exist then one that does exist will be substituted.
This isn't a BlueHost problem and it isn't a WordPress problem. It is a setup problem where you didn't create all the email accounts you are trying to use.
thomasw98
03-12-2009, 06:07 PM
Not for me. The email account has been setup properly in bluehost, but the problem still persists. So this explanation does not hold water in my view.
felgall
03-12-2009, 10:26 PM
Not for me. The email account has been setup properly in bluehost, but the problem still persists. So this explanation does not hold water in my view.
Well that was all I needed to do to get it working for my site.
wysiwyg
03-13-2009, 02:58 AM
It doesn't work for me either.
The email account is registered and functional, it's set as the email "used for admin purposes, like new user notification," in wordpress. And it doesn't work. Just sends mail from my username @ my box.
On the other hand, this does.
<?php
$to = "me@gmail.com";
$subject = "Hi!";
$body = "This is a test";
$headers = "From: admin@example.com";
if (mail($to, $subject, $body, $headers)) echo "Message sent!";
else echo "Message delivery failed...";
?>
Which means wordpress is screwing this up somehow. No two ways about it.
I did take a crack at their sendmail class, but it's 2000 lines long, and I'm just not that interested.
felgall
03-13-2009, 12:01 PM
Do you have any plugins installed into WordPress? The first place within Wordpress I'd suspect of causing such a problem would be interference from one of the plugins - that's about the only way you can have it working for some installations and not others.
wysiwyg
03-13-2009, 01:32 PM
No, I don't use wordpress. I just have it installed to test things.
There are different versions, which could cause differences between installations. But I don't think their sendmail file has changed in a long time. I'm using the latest version from their site.
agathoune
03-14-2009, 12:38 PM
I have double checked my email config and an sure that the account is created fine and sends fine (it's "notification@domain.com). However, as with thomasw98 and wysiwyg, when I set this as "used for admin purposes, like new user notification", it keeps sending from domain@box464.bluehost.com.
It seems to me there are 2 likely explanations: 1) Wordpress is sending the email without a proper From address (or something like this) so it defaults back to the bluehost domain generic address 2) There is something strange going on with the bluehost local/public domain resolution.
It's entirely possible that a plugin is causing something, but I have done very little customization and it seems odd that a plugin would interfere with such a critical a core wordpress function like sending emails from the administrator email address.
Any ideas? Here is the email header of a recent "password reset" email from my wordpress blog to a gmail account (I've Xed out my personal email):
**** start *****
Delivered-To: XXXXXX@gmail.com
Received: by 10.103.231.5 with SMTP id i5cs8930mur;
Thu, 12 Mar 2009 23:29:42 -0700 (PDT)
Received: by 10.115.110.1 with SMTP id n1mr646972wam.102.1236925780965;
Thu, 12 Mar 2009 23:29:40 -0700 (PDT)
Return-Path: <agathoun@box464.bluehost.com>
Received: from outbound-mail-122.bluehost.com (outbound-mail-122.bluehost.com [67.222.38.22])
by mx.google.com with SMTP id q18si6502330pog.9.2009.03.12.23.29.36;
Thu, 12 Mar 2009 23:29:40 -0700 (PDT)
Received-SPF: pass (google.com: domain of agathoun@box464.bluehost.com designates 67.222.38.22 as permitted sender) client-ip=67.222.38.22;
Authentication-Results: mx.google.com; spf=pass (google.com: domain of agathoun@box464.bluehost.com designates 67.222.38.22 as permitted sender) smtp.mail=agathoun@box464.bluehost.com
Received: (qmail 21322 invoked by uid 0); 13 Mar 2009 06:29:35 -0000
Received: from unknown (HELO box464.bluehost.com) (74.220.219.64)
by outboundproxy4.bluehost.com with SMTP; 13 Mar 2009 06:29:35 -0000
Received: from localhost ([127.0.0.1] helo=box464.bluehost.com)
by box464.bluehost.com with esmtp (Exim 4.69)
(envelope-from <agathoun@box464.bluehost.com>)
id 1Li0tj-0004JF-Oc
for XXXXXX@gmail.com; Fri, 13 Mar 2009 00:29:35 -0600
To: XXXXXX@gmail.com
Subject: [Agathoune!] Password Reset
Date: Fri, 13 Mar 2009 00:29:35 -0600
From: agathoun@box464.bluehost.com
Message-ID: <8ed99c178af039738c3539c15e241693@www.agathoune.com>
X-Priority: 3
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Content-Type: text/plain; charset="UTF-8"
X-Identified-User: {2528:box464.bluehost.com:agathoun:agathoune.com} {sentby:program running on server}
*** end ***
felgall
03-14-2009, 01:38 PM
See post 8 in at http://www.bluehostforum.com/showthread.php?t=12111 for a detailed description of where in WordPress you have to check the email address is set correctly.
agathoune
03-15-2009, 03:20 PM
SOLUTION FOUND - It's a Wordpress issue...
1) The default admin email address in wordpress is "wordpress@domain.com". This address is used for things like new user registration, password resets, etc.
2) Despite the fact that I changed it to a new address called "notification@domain.com" everywhere on the blog, it seems that wordpress still was using this address. After googling a bit, I realized that many wordpress users were having trouble updating this default admin notification email address. Apparently it seems you may need to edit it directly in the database (I have not yet tried this).
3) I had never created the address "wordpress@domain.com" on my bluehost domain (because I did not realize Wordpress was even trying to use it). Once I created this address, email notifications worked fine (From: address is now "wordpress@domain.com" - I think I'll leave it at that!).
Thanks for everyone's help and input on this!
wysiwyg
03-15-2009, 04:42 PM
Nicely done. This appears to be hard-coded into /wp-includes/pluggable.php. It's set to fill in the "from" field with wordpress@domain if $from_email isn't set. Why wordpress thinks it's not set is beyond me.
// If we don't have an email from the input headers
if ( !isset( $from_email ) ) {
// Get the site domain and get rid of www.
$sitename = strtolower( $_SERVER['SERVER_NAME'] );
if ( substr( $sitename, 0, 4 ) == 'www.' ) {
$sitename = substr( $sitename, 4 );
}
$from_email = 'wordpress@' . $sitename;
}
It's also set later in the same file for the notification emails for comments.
$wp_email = 'wordpress@' . preg_replace('#^www\.#', '', strtolower($_SERVER['SERVER_NAME']));
There is one other less-important place that it occurs, and that's in /includes/upgrade.php, for the "new blog" notification.
$message_headers = 'From: "' . $blog_title . '" <wordpress@' . $_SERVER['SERVER_NAME'] . '>';
duff man
03-24-2009, 10:01 PM
I'm having the same issue for vbulletin. The email sender is something like "boxname@box565.bluehost.com"
I totally can't have that happen... :(
felgall
03-25-2009, 12:33 AM
The simple solution is to create the sending email account so that it exists to receive any replies. The alternative is to set it up as a forwarder to a real email account. If neither of those exist then it will default to the email address you are currently getting.
duff man
03-25-2009, 08:27 AM
I just don't want them to see the main name of my account or the box number.
felgall
03-25-2009, 11:27 AM
I just don't want them to see the main name of my account or the box number.
So create an email account to use to send the emails from.
duff man
03-25-2009, 07:52 PM
is there a way to remove the box/username information from the email header?
EDIT: It's probably noteworthy for some folks that capitalization DOES matter. The caps were mismatched in the email addresses so it didn't work until it matched exactly.
felgall
03-25-2009, 11:22 PM
is there a way to remove the box/username information from the email header?
Only by using a different mail server. The path through each mail server the email goes through is added to the header so to not have a mailserver listed you need to make sure the email doesn't go through that server.
meaghannf
06-14-2009, 11:31 PM
I'm sorry, I'm still having issues here - I found wysiwyg's post very helpful and modified my php pluggable file so that the email address in the php file matches one on my server, as well as creating a wordpress@domain.com account just in case I didn't catch all the references (and to see if it would make any difference) and it is still sending emails from maindomain@box##.bluehost.com
I also tried to use the SMTP plugin suggested in this thread but it was receiving errors when ever it tried to connect or send, even though I verified my SMTP settings were correct.
Just to recap:
I have a domain hosted as a subdomain and am running Wordpress MU. I would like emails to appear from the address info@subdomain.com but they are currently appearing as domain@box.bluehost.com.
I have ensured the info@subdomain.com email account exists, modified the pluggable.php file in my wp-includes folder, attempted to use a SMTP plugin on WPMU and created a wordpress@subdomain.com catch-all email address, still no love.
Anyone have any other suggestions for this issue?
wysiwyg
06-16-2009, 06:56 AM
You can try hard coding the variable instead of letting it do whatever it's currently doing.
Replace
if ( !isset( $from_email ) ) {
// Get the site domain and get rid of www.
$sitename = strtolower( $_SERVER['SERVER_NAME'] );
if ( substr( $sitename, 0, 4 ) == 'www.' ) {
$sitename = substr( $sitename, 4 );
}
$from_email = 'wordpress@' . $sitename;
}
with this..
/*if ( !isset( $from_email ) ) {
// Get the site domain and get rid of www.
$sitename = strtolower( $_SERVER['SERVER_NAME'] );
if ( substr( $sitename, 0, 4 ) == 'www.' ) {
$sitename = substr( $sitename, 4 );
}
$from_email = 'wordpress@' . $sitename;
}*/
$from_email = 'info@mysite.com';
and
$wp_email = 'wordpress@' . preg_replace('#^www\.#', '', strtolower($_SERVER['SERVER_NAME']));
with
//$wp_email = 'wordpress@' . preg_replace('#^www\.#', '', strtolower($_SERVER['SERVER_NAME']));
$wp_email = 'info@mysite.com';
Note that the email domain probably needs to be the same as the one the script is running on.
Just disable any plugins you may be using while testing it.
meaghannf
06-16-2009, 11:49 PM
Thanks for that WYSIWYG - unfortunately still not solving the problem. Also changed my php.ini file, and have now been experimenting with http://www.callum-macdonald.com/code/wp-mail-smtp/
I am possibly a complete idiot here, but I keep getting errors with the wp-mail-smtp pluggin (which seems to have been the fall back solution for most people with this issue). Anyone using that? Where did you find your SMTP info? I was pretty sure I had it right but am getting boatloads of errors.
Thanks again.
meaghannf
06-17-2009, 02:11 PM
Ah! Solved the problem - hope this might help someone else!
WYSIWYG, your post before almost solved the problem but for some reason, even when I defined the from_email variable, the $phpmailer filters were still causing problems. I went into my wordpress pluggable file and changed lines (approximately) 340-360 to appear like this:
// From email and name
// If we don't have a name from the input headers
if ( !isset( $from_name ) ) {
$from_name = 'My Name';
}
// If we don't have an email from the input headers
/*if ( !isset( $from_email ) ) *{
// Get the site domain and get rid of www.
$sitename = strtolower( $_SERVER['SERVER_NAME'] );
if ( substr( $sitename, 0, 4 ) == 'www.' ) {
$sitename = substr( $sitename, 4 );
}*/
$from_email = 'info@mydomain.com';
// Set the from name and email
//$phpmailer->From = apply_filters( 'wp_mail_from', $from_email );
//$phpmailer->FromName = apply_filters( 'wp_mail_from_name', $from_name );
$phpmailer->From = $from_email;
$phpmailer->FromName = $from_name;
*Note that in the php code above I've left the original $phpmailer code in, just commented out so you can see what changed.
I imagine this would cause issues with Wordpress if you were using different email addresses for different automated messages but I'm pretty sure that's a fairly rare occurrence. In any case, this has entirely solved the problem, just defining the $phpmailer completely manually, not just defining the variables of the from_email and from_name alone.
jacobchr
06-17-2009, 06:03 PM
mail('someone@somewhere.com', 'test subject', 'test message');
This works BUT the "from:" is not nice.
---
$headers= 'Mime-Version:1.0'."\n".
'From: me@mysite.com'."\n"."\n";
mail('someone@somewhere.com', 'test subject', 'test message', $headers);
This works and the "from:" is nice -- "me@mysite.com"
---
mail('someone@somewhere.com', 'test subject', 'test message', $headers, '-r bounce@mysite.com');
This works and the "from:" is nice -- "me@mysite.com"
PLUS, if it is bounced, the bounce message goes to "bounce@mysite.com"
---
$headers= 'Mime-Version:1.0'."\n".
'From: me@mysite.com'."\n".
'X-Priority: 1'."\n".
'Content-Type: text/html; charset=iso-8859-1'."\n".
'Content-Transfer-Encoding: 7bit'."\n"."\n";
This has some more headers you may want to use.
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.