Hi,
i have mudified the mentioned members and the likers (in a separate line) so that the avatar is also shown.
everything works fine for the members mentioned
but the Likers only avatars are displayed that were uploaded via the upload function of wpForo
Gravatars or Letters Avatar (plugin) are not displayed
i use this code for the likers, adjusted to the number of likers [0][1][2]
' . esc_url(WPF()->member->get_avatar_url($l_usernames[0]['ID'])) . '
can someone give me the correct code that all avatars are displayed 😉
Hi @tutrix,
Try this methods in Members Class
WPF()->member->get_avatar()
or
WPF()->member->avatar()
have now tested different versions with your code, but always gives an error
What error are you getting?
if you know the right code, just post it
No, I don't use any such function. The reason I asked is I thought you were getting a php error which might have been helpful to wpForo support, but it seems you are not getting those.
Have now found the correct code 😀
are these 3 lines for the 3 displayed Likers
<span class="nickname-ava">' .WPF()->member->get_avatar($l_usernames[0]['ID']). '</span> <span class="nickname-ava">' .WPF()->member->get_avatar($l_usernames[1]['ID']). '</span> <span class="nickname-ava">' .WPF()->member->get_avatar($l_usernames[2]['ID']). '</span>