Change Directory llisting


Home Forums Front End PM PRO Change Directory llisting

This topic is: Resolved

Tagged: 

  • This topic has 5 replies, 2 voices, and was last updated 7 years ago by M G.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #8114
    M G
    Participant

    Hi Shamim,

    Is it possible to display the store name of the users instead of their display name in the directory?

    Thanks

    #8117
    M G
    Participant
    This reply has been marked as private.
    #8127
    Shamim Hasan
    Keymaster

    what is meta name of that field? Did you use any plugin to create that field?

    #8130
    M G
    Participant
    This reply has been marked as private.
    #8141
    Shamim Hasan
    Keymaster

    Please add following code in your theme’s (child theme’s if any) functions.php

    
    add_action( 'fep_directory_table_column_content_name', function( $user ){
    	$shop_name = get_user_meta( $user->ID, 'pv_shop_name', true );
    	if( $shop_name )
    	echo $shop_name;
    	else
    	echo $user->display_name;
    });
    
    #8340
    M G
    Participant

    Thank you for your awesome support.

Viewing 6 posts - 1 through 6 (of 6 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.