BuddyDev

Recent Visitors For BuddyPress Profile

BuddyPress Recent Profile Visitors Plugin shows the most recent profile visitors on a user profile as well as the most popular users on a BuddyPress site.

If you are looking for:-

  • Allowing users to see who visited their profile recently on BuddyPress social network
  • And/or Listing the most popular users on your BuddyPress site

Then the BuddyPress Recent Profile visitors  is the most suitable solution.

Features:-

  • The plugin records users who viewed profiles recently
  • Based on your settings, a user can see who viewed their profile
  • You can show the most popular users on your site over a period of time. For example, you can list top 10 users on your BuddyPress site over last 30 days(or 7 days etc)
  • You can also turn on/off the plugin(using code) for users based on roles. For example, you may charge users (Using any of the subscription plugin) and based on their status, you can use a small snnipet of code to show/hide the recent visitors.
  • The plugin comes with widget for most popular BuddyPress users as well as shortcodes for listing the most popular users on BuddyPress site, recently visiting user for a given user(or logged in)
  • The plugin also lists the most recent visitors of a user on his profile, in the members directory( a new tab) and if enabled, with a new component on profile(where user can see who visited them in last 7 days, 30 days and all time).
  • All the plugin features can be turned off easily(Please see the bottom of this page)

The profile visiting recording can be turned on/turned off by a user. It is also possible to exclude users belonging to some roles from recording. The whole feature can be turned on/off based on roles( please see code example section). The recent visitors can also be enabled as a tab and a shortcode is also available to display the recent visitors list anywhere.

Screenshots:-

 

When the profile visit is turned off, It will not show the user who visited their profile. The visits display must be mutual,  if a user want to see who visited their profile, they should keep the settings on. Once the user turns the settings off, It will not record any data for them. As a site admin, you can override this behaviour.

Documentation:-

Installation:-

1. Download the plugin
2. Unzip recent-visitors-for-buddypress-profile-xyz.zip
3. Upload recent-visitors-for-buddypress-profile to wp-content/plugins
4. Go to Dashboard->Plugins->Installed and activate “BuddyPress Recent Profile Visitors”
5. Let the plugin do its magic.
Alternatively, you can use wp-admin->Plugins->Add New, click on the upload tab and browse this zip file, upload and click activate, you are done.

Upgrading:-

We suggest using BuddyDev Dashboard plugin to allow automatic upgrade.

Using the Most Visited Users widget:-

Please visit Appearance->Widget and Add the “Most Visited Users” widget to your desired widget area.

The widget provides following options:-

BuddyPress Most visited users widget options

You can select the view to be slider or the default list. View count can be shown beside the users.

 

Using Shortcode:-

The plugin provides two shortcodes

  • [bp-visitors-most-visited-users] to list most visited/popular users.
  • [bp-visitors-recent-visitors] to list the recent visitors to a specific user.

Showing most popular users using the shortcode:-

You can use the [bp-visitors-most-visited-users] shortcode to show the most popular users on your site. The shortcode provides following options:-

  • view:- ‘slide’ or ‘list’
  • max:- int, how many entries at most to show.
  • duration:- int, for how many days
  • show_visits:- 1 or 0, do you want to show the view count for the profiles.

Example:- Show the most popular users for the last 7 days in slide view.

[bp-visitors-most-visited-users view=”slide” max=”5″ duration=”7″ show_visits=”0″]

Showing recent visitors using shortcode:-

You can use the shortcode [bp-visitors-recent-visitors] to show the list of recent visitors. By default, It shows 5 recent visitors of the logged in user. The shortcode provides following options:-

  • user :- It can be username (like sbrajesh, or email like someone@example.org or user Id). If this user exists, It will list the visitors of this user. By default, It is set to current logged in user.
  • max:- It is the maximum no. of visitors to show. default is 5.
  • duration:- You can set the maximum no. of days to take in account. default is set to 0. It means all time. You can set it to 7  to show the recent visitors in last 7 days.

Example:-

[recent-visitors user=sbrajesh max=20 duration=7]

The above shortcode will display 20 most recent visitors in the last 7 days for the user sbrajesh.

 

Modifying the plugin settings:-

With version 1.5.0 and above, you do not need to touch any code. Please use the admin panel. If you are upgrading from an older version to 1.5.0 and have used the custom code earlier, we suggest removing the custom code for better experience with the admin panel.

You can filter on ‘bp_visitors_settings‘ to modify the settings(Only use if you are using an older version, we will remove the filter or rename it in 1.5.1).

Here is an example to show 10 recent visitors in the list.

 

Most of the BuddyPress theme will automatically display the recent visitors using   the action hook “bp_after_member_header”, If your theme does not display it(  make sure someone has visited your profile before the conclusion)  you can always call

It will list the most recent 5 visitors.

Code snippets:-

Some example codes:-

 

Release History

  • Version: 1.5.5

    Saturday, 27 July, 2019
    • Tested With: BuddyPress 4.4
    • Compatible With: BuddyPress 2.5+

    Added email template. Now site admin can modify email format from "Emails menu" in the backend.

  • Version: 1.5.4

    Thursday, 06 December, 2018
    • Tested With: BuddyPress 4.1
    • Compatible With: BuddyPress 2.5+

    Fix count for the visitor tab when some of the members are hidden.
    Released on: 05/15/2018

  • Version: 1.5.3

    Tuesday, 13 February, 2018
    • Tested With: BuddyPress 2.9.3
    • Compatible With: BuddyPress 2.5+

    Added compatibility with BuddyPress Profile Visibility Manager for honouring the privacy.
    Released on: 09/15/2017
    Last tested: 02/13/2018

  • Version: 1.5.2

    Sunday, 03 September, 2017
    • Tested With: BuddyPress 2.9.1
    • Compatible With: BuddyPress 2.5+

    Fixes the visibility of Visitors tab on profile.
    Fixes the user list in the sitewide popular users list.

  • Version: 1.5.1

    Sunday, 03 September, 2017
    • Tested With: BuddyPress 2.9.1
    • Compatible With: BuddyPress 2.5+

    Added filters on the where conditions for sql.
    Added compatibility with Simple BuddyPress Profile Privacy

  • Version: 1.5.0

    Monday, 24 July, 2017
    • Tested With: BuddyPress 2.8.2
    • Compatible With: BuddyPress 2.5+

    Add extensive admin options panel to allow customize each feature of the plugin.

  • Version: 1.4.1

    Sunday, 18 June, 2017
    • Tested With: BuddyPress 2.8.2
    • Compatible With: BuddyPress 2.5+

    Added Most visited Users widget & shortcodes.
    Also, Completely cleaned up code for wp standards. It makes it easy to provide a complete admin settings in our next release.

  • Version: 1.4.0

    Friday, 26 May, 2017
    • Tested With: BuddyPress 2.8.2
    • Compatible With: BuddyPress 2.5+

    - Allow disabling the plugin features completely for some of the profile types
    - Allow excluding some of the roles from getting recorded
    -Allow site admin to use a recording policy( always record visitors or only record if the virtors and the displayed user both have it enabled)
    -Refactor partially.

  • Version: 1.3.1

    Wednesday, 02 March, 2016
    • Tested With: BuddyPress 2.5.1
    • Compatible With: BuddyPress 2.0+

    Fix privacy issues if the component screen is enabled

  • Version: 1.3.0

    Saturday, 12 September, 2015
    • Tested With: BuddyPress 2.3.3
    • Compatible With: BuddyPress 2.0+

    Fixes the user display issue on visitor component page

  • Version: 1.2.9

    Friday, 11 September, 2015
    • Tested With: BuddyPress 2.3.3
    • Compatible With: BuddyPress 2.0+

    Updated to avoid issues when BuddyPress settings component is disabled.

  • Version: 1.2.8

    Thursday, 30 July, 2015
    • Tested With: BuddyPress 2.3.2.1
    • Compatible With: BuddyPress 2.0+

    Major Changes:-
    * Folder name change from recent-visitors-for-bp to recent-visitors-for-buddypress-profile to allow us autoupgrade in future.
    * The update allows the visitor object to be accessible in the template generation function instead of the visitor_id
    * A custom output can be generated by filtering on 'visitors_pre_item_html'

  • Version: 1.2.7

    Thursday, 05 February, 2015
    • Tested With: BuddyPress 2.2.0
    • Compatible With: BuddyPress 2.0+

    Skipping version 1.2.6.
    added support for custom avatar size
    added support for enabling/disabling user settings

  • Version: 1.2.5

    Tuesday, 09 September, 2014
    • Tested With: BuddyPress 2.0+
    • Compatible With: BuddyPress 1.9+

    #added size option in the shortcode using size parameter for controlling avatar size

  • Version: 1.2.5

    Saturday, 16 August, 2014
    • Tested With: BuddyPress 2.0.2
    • Compatible With: BuddyPress 1.9+

    Updated to add the the User notification features( Local BuddyPress notification and By email notification for new profile visits).

  • Version: 1.2.4

    Tuesday, 12 August, 2014
    • Tested With: BuddyPress 2.0.2
    • Compatible With: BuddyPress 1.9+

    Updated to allow disabling of the directory tabs for recent visitors

  • Version: 1.2.3

    Wednesday, 23 April, 2014
    • Tested With: BuddyPress 2.0
    • Compatible With: BuddyPress 1.9+

    Updated to add last visit time in the component screen if it is enabled. Also, fix the visibility issue that was introduced in 1.2.2

  • Version: 1.2.2

    Monday, 14 April, 2014
    • Tested With: BuddyPress 1.9.2
    • Compatible With: BuddyPress 1.8+

    Updated to add filtering on the visitors component for 7 days, 30 days. Also added support on Member directory .

  • Version: 1.2.1

    Thursday, 27 March, 2014
    • Tested With: BuddyPress 1.9.2
    • Compatible With: BuddyPress 1.7+

    Updated to fix the template loading issues on Visitors component page

  • Version: 1.2

    Wednesday, 26 March, 2014
    • Tested With: BuddyPress 1.9.2
    • Compatible With: BuddyPress 1.7+
Subscribe