Viewing 5 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic.
Hi!
How can i return the URL Followers and Follwing?
I use this:
echo $userpro_social->following_count_plain( $user_id );
and
echo $userpro_social->followers_count_plain( $user_id );
but i would like to link!
Can anyone help me? 😛
I need to display the URL to make a link. like: site.com/following/usernameviewed
When i use this echo $userpro_social->following_count_plain( $user_id ); i return the number, but not have the link!
You can use API to do this.
Use this to generate link for FOLLOWERS
echo $userpro->permalink($user_id, 'followers', 'userpro_sc_pages');
For FOLLOWING same
echo $userpro->permalink($user_id, 'following', 'userpro_sc_pages');
Remember to change $user_id with the dynamic user ID you want. This will link to followers/following page for specific user.
if i put $user_id that will work? For me works, this shows from a user that im viewing the profile 🙂
user_id need to be dynamically set. Depends on where you use that code /snippet
You must be logged in to reply to this topic.