• I have been trying to figure this out for hours. I would really appreciate any help.

    I set up a subdomain on my server and had it point to a specific folder (i.e. http://www.meetjustin.com/Community would be seen as community.meetjustin.com).

    I then installed WP 2.0 – a fresh copy – on the subdomain. Everything worked perfectly. I tested registering a new user – got the email both at my test address and at the admin address letting me know a new user signed up.

    I then went into WP options and changed the “Blog address (URI)” and the “WordPress address (URI)” to match the subdomain – community.meetjustin.com.

    As soon as I did that the new user registration, lost password, and admin emails all stopped.

    When I changed the URIs back it didn’t fix the problem. It seems that WP 2.0 uses cache files – I had to flush the cache files before the emails would start working again.

    I then tested each of the URIs and found that it was the “Blog Address (URI)” which is causing the problem. As long as I leave it as is, everything works fine.

    Of course, this leaves me back at square one. I want my ‘siteurl’ to be community.meetjustin.com and not http://www.meetjustin.com/Community.

    Can any of you code wizards help me out of give me some guidance on this?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Can you confirm with your host that the mails were not sent? The host can check the mail server log files. It’s quite possible that WordPress generated the emails but the host rejected them.

    My guess would be that when E-mails are sent from a subsite (community.meetjustin) they might get filtered in one way or another, at some stage or another. What happens if you try a variation of the name (a test address, that is)? One which is not a subsite? It might help identify a pattern and thus the root of the problem.

    Thread Starter meetjustin

    (@meetjustin)

    Thanks for replying Skippy.

    I just checked my mailError.log on the server and sure enough there were errors.

    Result: 9
    2005 Dec 29 19:27:07 From address not in member domain. Message not sent.

    How would changing the Blog Address (URI) affect this? When I change it back to the non-subdomain URI the emails go out fine.

    Any ideas?

    Your mail host’s mail server is configured to permit mail from foo.com, but not bar.foo.com. This is an anti-spam mechanism, designed to prevent the ISP from being used for (too much) spam.

    Contact your host and ask them to permit your subdomain to send mail.

    meetjustin –

    This is a little off the direct topic, but I was wondering if you could shed any light on how you got the permalinks working with a subdomain in WP2.0?

    Reference: http://wordpress.org/support/topic/53662

    Thanks!

    Thread Starter meetjustin

    (@meetjustin)

    Skippy – I have the subscribe-to-comment plugin sending me emails from within the subdomains just fine.

    When I reply to any comments I get an email from travel@meetjustin with the subject that begins with [Travel.MeetJustin.com].

    I am hosting with Yahoo which I know limits php emailing but I was able to get around this on other blogs with some changes to the pluggable-functions.php.

    Thread Starter meetjustin

    (@meetjustin)

    I got it to work by changing around some of the code in pluggable-functions.php!

    Wohoo!

    Feel free to email me if you are having the same problem. webmaster@meetjustin.com.

    Thanks for all your comments!

    Why not share your changes here, so that people searching in the future can get the answer, instead of an email address?

    Thread Starter meetjustin

    (@meetjustin)

    ———————
    To get comments to email, go into pluggable-functions.php
    ———> CHANGE TO THIS <—————-
    ———————

    $admin_email = get_settings(‘admin_email’);

    if ( ” == $comment->comment_author ) {
    $from = “From: \”$blogname\” <$admin_email>”;
    if ( ” != $comment->comment_author_email )
    $reply_to = “Reply-To: $comment->comment_author_email”;
    } else {
    $from = “From: \”$comment->comment_author\” <$admin_email>”;
    if ( ” != $comment->comment_author_email )
    $reply_to = “Reply-To: \”$comment->comment_author_email\” <$comment->comment_author_email>”;

    }

    $message_headers = “MIME-Version: 1.0\n”
    . “$from\n”
    . “Content-Type: text/plain; charset=\”” . get_settings(‘blog_charset’) . “\”\n”;

    if ( $reply_to )
    $message_headers .= $reply_to . “\n”;

    $notify_message = apply_filters(‘comment_notification_text’, $notify_message);
    $subject = apply_filters(‘comment_notification_subject’, $subject);
    $message_headers = apply_filters(‘comment_notification_headers’, $message_headers);

    @wp_mail($user->user_email, $subject, $notify_message, $message_headers);

    return true;
    }
    endif;

    ———————
    AND THIS
    ———————

    if ( !function_exists(‘wp_mail’) ) :
    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”;
    }

    return @mail($to, $subject, $message, $headers);
    }
    endif;
    ———————

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Change “Blog address (URI)” in WP 2.0 – No more emails’ is closed to new replies.