• Resolved joorkataa

    (@joorkataa)


    Hello, I have a problem with the avatars in the forum, does anyone have an idea how I can fix it?
    I’m attaching a photo, I’m using the Classiads theme

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author gVectors Team

    (@gvectors-team)

    Hi @joorkataa,

    Please move the support topic to wpForo Support Forum and mention the plugin name you use for members avatars: https://wpforo.com/community/

    Thread Starter joorkataa

    (@joorkataa)

    I wrote there but I don’t have an answer.

    This code i have given below is to generate my avatar can it be made to generate users avatar

    <?php 
    				$authorID = get_the_author_meta('ID');
    			//$author_name = get_the_author_meta('display_name', $authorID);
    					$output = '';
    					//$author_img_url = get_user_meta($authorID, "pacz_author_avatar_url", true); 
    					$avatar_id = get_user_meta( $authorID, 'avatar_id', true );
    					
    					//$author_img_url = get_the_author_meta('pacz_author_avatar_url', $authorID, true); 
    					$output .='<div class="author-thumbnail">';
    					if(!empty($avatar_id) && is_numeric($avatar_id)) {
    						$author_avatar_url = wp_get_attachment_image_src( $avatar_id, 'full' ); 
    						$src = $author_avatar_url[0];
    						$params = array( 'width' => 60, 'height' => 60, 'crop' => true );
    						$output .= "<img src='" . bfi_thumb( $src, $params ) . "' alt='' />";
    					} else { 
    						$avatar_url = get_avatar_url($authorID, ['size' => '60']);
    						$output .='<img src="'.$avatar_url.'" alt="author" />';
    										}
    					$output .='</div>';
    					echo $output;
    			?>

    Plugin Support gVectors Dev

    (@gvectorsdevs)

    @joorkataa,

    Answer given in wpforo.com/community topic.

    Thread Starter joorkataa

    (@joorkataa)

    Well, I read all the threads there and I didn’t find a solution to the problem, I tried absolutely everything but it doesn’t work… :/

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Problem with avatars’ is closed to new replies.