Re: Email coming from "wordpress", how to change this
i could write a plugin for this. however i dont like running any more plugins than i have to since it slows down the site. So here is a non-plugin solution. (i just like hacking code is the real reason tbh)
First lets chnage the from name.
Open the "pluggable.php" file found in your "
wp-includes" folder of your wordpress install.
About line 351 look for this:
Code:
if ( !isset( $from_name ) ) {
$from_name = 'WordPress';
}
Just change the wordpress to a name you would like, for example:
Code:
if ( !isset( $from_name ) ) {
$from_name = 'EricHamby.Com';
}
Now to chnage the address.
On line 362 you should see this.
Code:
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;
}
Also change the term "wordpress@" to something you would like. Example:
Code:
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 = 'eric@' . $sitename;
}
Have fun hacking and changing code
If you still would rather have the plugin version let me know and ill write it real fast.
Eric is best known in the forum for his in depth tutorials. He started in design 4 years ago and then discovered WordPress and has been coding and hacking themes and plugins ever since. He's quite helpful if you have any questions for him in the forum. Eric also makes his own WordPress themes and plugins and provides ClassiPress consulting on the side. David Cowgill - (Owner of Classipress)