WordPress.org

Ready to get started?Download WordPress

Forums

Ultimate Blogroll
[resolved] Send mails in UTF-8.. (3 posts)

  1. syndrael
    Member
    Posted 1 year ago #

    In domain/UbMain.php the function sendMail() sends in charset iso-8859-1 which can problems with some languages like French for example.
    Could you change it by something like that: $headers .= 'Content-type: text/html; charset='.get_option('blog_charset'). "\r\n";

    If it could help you here is what un modify:

    public function sendMail($linkpartner, $id) {
            ob_start();
            require_once(UB_PLUGIN_DIR."gui".DIRECTORY_SEPARATOR."Mail.php");
            $body = ob_get_clean();
            $headers  = 'MIME-Version: 1.0' . "\r\n";
            $headers .= 'Content-type: text/html;' . "\r\n";
             $headers .= 'From: WordPress Ultimate Blogroll <'.get_bloginfo('admin_email').'> '."\r\n";
             $subject = __("New link submitted at", "ultimate-blogroll")." ".home_url().''."\r\n";
            if(function_exists('wp_mail')):
                add_filter('wp_mail_charset',create_function('', 'return \''.get_option('blog_charset').'\'; '));
                wp_mail(UbMapper::getInstance(UbMapper::Settings)->getConfig("blogroll_contact"), $subject, $body, $headers);
            else:
                mail(UbMapper::getInstance(UbMapper::Settings)->getConfig("blogroll_contact"), $subject, $body, $headers);
            endif;

    Best regards
    S.

    http://wordpress.org/extend/plugins/ultimate-blogroll/

  2. jensg
    Member
    Plugin Author

    Posted 1 year ago #

    Sure! will do.
    I don't get mails from wordpress when somebody posts something in the forum.

  3. syndrael
    Member
    Posted 1 year ago #

    Ok, in the next update.
    Best regards

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.