Preview or clickable profile / Avatar so you know who is messaging you.


Home Forums Front End PM PRO Preview or clickable profile / Avatar so you know who is messaging you.

This topic is: Not Resolved
Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #34127
    Neta Lubik
    Participant

    Hi
    I am building a dating site; and need the person who receives a message from someone, to be able to click on the username that is in the “participants” field, and or click on the Avatar, in order to be taken to that persons profile who is contacting them.

    1 how can we make the participants field “usernames” (clickable) in order to be taken to their profile. And or
    2 Avatar clickable? if so how do we keep them in the cell phone view?
    3 how could we have a preview of the other persons profile on the “chat page” so as people commune they see who they are talking to..?
    the last solution would be ideal

    Attachments:
    You must be logged in to view attached files.
    #34226
    Shamim Hasan
    Keymaster

    By default wordpress does not have any nice user profile. So we cannot show user profile link.
    But you can get an idea from https://www.shamimsplugins.com/support/topic/how-to-link-the-participants-name-to-their-profile/page/2/#post-26441

    #34256
    Neta Lubik
    Participant

    Ok I see the code. Where would I place this code? and how would I out put “the link?” on the chat page.. I’m sorry I’m a bit new.. How would I output it..

    Lastly what exactly will it do? I had the 3 items up there, what one would it work for?

    #34278
    Shamim Hasan
    Keymaster

    It will do No.1.
    This is a little advanced. You will have to have some knowledge in php.
    What plugin you are using to create user profile?

    #34316
    Neta Lubik
    Participant

    “What plugin you are using to create user profile?” Profile builder pro
    https://www.cozmoslabs.com/search/?swpquery=notifications+to+admin&swp_category_limiter=140&submit=Search

    I have some understanding of php but not much I can obesely past in the code given to the pages you direct me to..

    #34322
    Shamim Hasan
    Keymaster

    Can you ask that plugin developer how can we get user profile page url from user id or user nicename in php code?

    #34326
    Neta Lubik
    Participant

    Yes let me ask thanks for your help…

    #34353
    Neta Lubik
    Participant

    This was his reply

    Hello Neta,

    First visit your front-end all user listing, and then a click user listing.

    You will see that the URL of a single user listing will have this form:

    https://yoursite.com/your-all-userlisting-page/user/85/

    Next, all you need to do is replace 85 with the wanted user ID.

    With best of regards,

    #34361
    Shamim Hasan
    Keymaster

    add following code in your theme’s (child theme’s if you are using) functions.php

    add_filter( 'fep_filter_user_name', function( $name, $id ){
    	if ( $name && fep_get_the_id() ) {
    		$name = '<a href="https://yoursite.com/your-all-userlisting-page/user/'. $id . '/">' . $name . '</a>';
    	}
    	return $name;
    }, 10, 2);
    

    Change your website your user listing page actual url.

    #34368
    Neta Lubik
    Participant

    omg thank you so much.. So on the other options can I pay to have code written for the preview?

    #34378
    Neta Lubik
    Participant

    Ok great! this is the code & it works!! ty – but if there is no “Avatar” uploaded you get the <a href= tag showing .. now.. I attached the screen shot .. how dow we get ride of this? and or have the profile image of the profile in its / Avatar place? here is the meta – name top_profile_photo.

    add_filter( ‘fep_filter_user_name’, function( $name, $id ){
    if ( $name && fep_get_the_id() ) {
    $name = ‘‘ . $name . ‘‘;
    }
    return $name;
    }, 10, 2);

    Attachments:
    You must be logged in to view attached files.
    #34403
    Shamim Hasan
    Keymaster

    This plugin uses wordpress gravatar. That means you can use any wordpress hook to change this avatar. If you use any plugin which allow upload profile image, that plugin also may have option to change gravatar image. You can ask that plugin developer.
    Let me know if they do not assist you.

Viewing 12 posts - 1 through 12 (of 12 total)

You need to purchase ‘Front End PM PRO’ to create topic in this support forum.

If you already purchased ‘Front End PM PRO’ please LOGIN.