![]() |
Show avatar in PM, I wrote the plugin but there is error !
Hi dears,
I want to write a plugin to show the user avatars in PM list (inbox/outbox....etc) I added this plugin: Code:
require_once('./includes/functions_user.php'); Then I added this to template(pm_messagelistbit) Code:
<img src="{vb:raw pm.avatarurl}" /> It is working and the avatar shows but only in first row ! I mean there is avatar only in FIRST pm (one avatar in each page). Any help? |
Which hook did you use for your plugin?
|
Quote:
private_messagelist_messagebit |
It works just fine for me (although the avatars are huge - you probably want the thumbnail size ones).
|
Quote:
https://vborg.vbsupport.ru/showthread.php?t=277502 I will contact with Joe Thanks Lynne. Thanks Kevin :) |
1 Attachment(s)
I faced another issue
In inbox it is working perfect but in (send folder / outbox) it shows the avatar for sender (my avatar) I want to show the avatar for the user who will receive the message. This is the Inbox (OK) https://vborg.vbsupport.ru/attachmen...1&d=1371463500 This is the send folder (All shows my avatar only!) https://vborg.vbsupport.ru/attachmen...1&d=1371463500 |
Maybe you could do something like:
Code:
$avid = $pm['fromuserid']; |
Quote:
Sorry Kevin but could you please explain this more? Should I add the previous code to the same plugin? Thanks very much |
You would add it above this line:
$pm[avatarurl] = fetch_avatar_url($pm['fromuserid']); But also change that line to: $pm[avatarurl] = fetch_avatar_url($avid); |
Quote:
I did but it is not working, all avatars is broken and I got this error above the page Code:
This is the plugin after modified Code:
require_once('./includes/functions_user.php'); |
All times are GMT. The time now is 03:51 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|