"Send PM" button on post / profile not working

3 Nov 2019
#1
This issue is marked as solved
When trying to send PM to a user by clicking on "Send pm" in forum post or in profile.
Link redirect to correct url
private.php?action=send&uid=1

But uid is "undefined" in the new conversation recipient.
This error is also happening on mybboost.

Best answer

Shade 31 Mar 2020 Edited
Got some time and implemented a simple yet efficient fix for this, which is now live on MyBBoost. Will be rolled out with beta 3. If you want to apply the patch to beta 2, open inc/plugins/symposium.php, find the function symposium_private_send_start and add under $uid = (int) $mybb->get_input('uid'); the following piece of code:

// Redirect to appropriate conversation if existing
    
$convid get_conversation_id($mybb->user['uid'], $uid);

    
$query $db->simple_select('symposium_conversations''uid'"uid = {$mybb->user['uid']} AND convid = '" $db->escape_string($convid) . "'");
    if (
$db->fetch_field($query'uid')) {
        
header('Location: private.php?action=read&convid=' $convid);
        exit;
    } 
In order to test this feature, click on the Message button on the new hovercards on usernames.

All replies

Shade 14 Aug 2020
#11
It should load the user into the recipients field.