• I’m modifying this private message plugin and I’ve done everything I need to do with two exceptions. One is in the message system’s header in the front end, where it says, “Welcome: user_login”, and the other is in its front-end directory, where it lists all of the users by user_login and provides a link to message them. I want to change both instances of user_login to display_name, but I can’t figure out how to call it up. Just changing user_login to display_name simply makes the that text disappear on the page. Here are the two bits of code I’m trying to modify:

    (1)
    $header .= get_avatar($user_ID, 60).”<p>“.__(“Welcome”, “cartpaujpm”).”: “.$user_login.”
    “;

    (2)
    function dispDirectory()
    {
    $users = $this->get_users();
    $directory = “”;

    foreach($users as $u)
    {
    $directory .= ‘<p>‘.$u->user_login.’actionURL.’newmessage&to=’.$u->ID.'”>’.__(‘Send Message’, ‘cartpaujpm’).’</p>’;
    }
    return $directory;
    }

    I can provide a link to my site but you have to be registered and logged in to see the problem. If someone thinks they can help, I’ll provide you a basic account if necessary. Many thanks for any help!

  • The topic ‘Private Message Plugin: Change user_login to display_name’ is closed to new replies.