Hi Brajesh, I’m using Recent Profile Visitors plugin, but have discovered an issue in relation to adding a hook to the visitors page.
If I place <?php bp_send_private_message_button(); ?> in the bp_after_member_body custom hook, the private message button should only be displayed on the profile page, which it does, except for the visitors page, where it is displayed in the body of the Recent Profile Visitors page, according to the hook attached.
I guess this must be a bug?
Regards
CarstenHi Carsten,
Please share 2 screenshots to show me the issue. I will need more details to provide assistance.Regards
BrajeshHi Brajesh here are 2 screenshots of what is going on. My point is, that the bp_send_private_message_button is acting correctly, except on visitors page, by only showing on profile pages. I hope this makes sense.
Using the hook: bp_after_member_body:
https://domain/members/jeff/
https://imgur.com/HnxO0UmSend message button also displayed on https://domain/members/jette/visitors/
https://imgur.com/5HnLv2kHere of course the button is inactive, but is displayed.
Regards
CarstenHi Carsten,
I am sorry, I do not see anything wrong with that.You are using the ‘bp_after_member_body’ which gets fired on all user pages. That’s why the button is visible.
I am not sure of your purpose but you should most probably use a different hook.
Regards
BrajeshHi Brajesh, thanks for your reply.
My point is, that the Send Private Message button with that hook is following the convention of only showing on profile pages, where it makes sense to send a message.
Not on users own profile page, the settings page, the members directory page, or any other BP page than the recent visitor page.
Not a big issue, I can probably hide it with css on recent visitors page.
Regards
CarstenHi Brajesh, just to clarify my question and why this is important. Of course it makes no sense to have a send private message button anywhere else than on profile page.
<?php bp_send_private_message_button(); ?> in the bp_after_member_body custom hook
Why is the button displayed in /visitors but not in /members directory, the hook must be the same for those two directories?
visitors directory
/visitors
https://imgur.com/8ShJ4Twmembers directory
/membersRegards
CarstenHi Carsten,
is it site/visitiros page or is it site/members/member_name/visitors page?The hook ‘bp_after_member_body’ fires on profile page(single user pages and not in the directory).
Regards
BrajeshHi Carsten,
Thank you.
By profile, do you mean the “members/member_name/profile/ page?Regards
Brajesh
You must be logged in to reply to this topic.