Best practice forum (Archived)

تمت إزالة منتدى المناقشة هذا

 
لقد تمت إزالة مشاركة المنتدى هذه
Thursday, 13 June 2013, 7:31 AM
تمت إزالة محتوى هذه المشاركة في المنتدى ولم يعد من الممكن الوصول إليها
Nathan Lewis
Re: Email Bug 2.4.0
بواسطة Thursday, 13 June 2013, 2:36 PM - Nathan Lewis
مجموعة Totara

Hi Luke.

I was working on another patch the other day and I came across a problem which might be the same one that you are experiencing. Below I've pasted the code fragment of the change I made. It would be great if you could patch your file with this change, try it out and let me know if it fixes your problem. If it does then I'll pull it into a separate patch and make sure it's in the next release of Totara. If it doesn't then someone will have a better look to see whats going on (I'm currently not on support, but someone here will help). Also let me know if you have trouble figuring out how to insert the change and I can send you a patch file or something.

Nathan

 

In message/lib.php, in function message_post_message

 

    //using string manager directly so that strings in the message will be in the message recipients language rather than the senders
    $eventdata->subject          = get_string_manager()->get_string('unreadnewmessage', 'message', fullname($userfrom), $userto->lang);

/* modified lines start here */

    $eventdata->fullmessagehtml = $message;
    if ($format == FORMAT_HTML) {
        //some message processors may revert to sending plain text even if html is supplied
        //so we keep both plain and html versions if we're intending to send html
        $eventdata->fullmessage = html_to_text($eventdata->fullmessagehtml);
    } else {
        $eventdata->fullmessage = $message;
    }


/* end of change */


    $eventdata->fullmessageformat = $format;
    $eventdata->smallmessage     = $message;//store the message unfiltered. Clean up on output.

لقد تمت إزالة مشاركة المنتدى هذه
Friday, 14 June 2013, 12:40 AM
تمت إزالة محتوى هذه المشاركة في المنتدى ولم يعد من الممكن الوصول إليها