BuddyPress Member Types Pro helps you setup conditional redirect for your users when they register or login to your site.
Conditional Login redirect based on BuddyPress Member Types:-
This is the first option you get under the redirection settings. If you specify a dynamic/absolute url, The user with this member type will be redirected to that url when they login. To create dynamic url, please see the available tokens and example sections at the bottom of this document.
Conditional Account Activation Redirect based on BuddyPress Member Types:-
With this option, you can specify where the user will get redirected after they activate their account. It supports the same set of tokens.
The Account Activation redirect works with the following plugins too
Profile landing tab option:-
It is an experimental option and may change in future.
At the moment, you may enable it based on
- If the logged in user has this member type
- If the displayed user has this member type
- Flexible option:- If a logged in user visits the profile, logged in user’s member type will be tested against this. if a non logged in visitor visits a profile, displayed user’s member type will be tested against this member type.
The slug specifies which component you want to set as default landing component.
URL Tokens and Dynamic URLs
Since the member type, username, login, id etc are dynamic piece of data, you can use tokens in place of them to create dynamic url. The tokens are express as [token_name] There are no spaces after/before the opening/closing bracket symbol.
Following tokens are supported
- [site_url] :- It will be parsed to represent current blog’s home url e.g www.example.com
- [network_url] :- On multisite, It is replace with the network’s home url. On non multisite, It is same as [site_url]
- [user_pofile_url] :- Points to the logged in/activated user’s BuddyPress profile e.g http://example.com/members/xyz/
- [username] :- User’s username used in the urls. e.g ‘sbrajesh’
- [user_login] :- It is the login name that user uses. eg. ‘alpha’
- [user_nicename] :- This is url friendly user_login
- [user_id] :- the actual numeric id of the user e.g 5, 7 etc.
- [member_type] :- The member type of the user e.g ‘student’, ‘developer’ etc.
Example:- Url to point to a page ‘welcome’ on example.com
the dynamic url will be [site_url]welcome
Example 2:- URl to point to support forums e.g www.example.com/support/forums/
[site_url]support/forums
As you see, the site url replaces the url of your installation.
Example 3:- Url to point to user’s groups page e.g www.example.com/members/member_name/groups/
[user_profile_url]groups
and so on.
In case of any confusion, Please post in our support forums and we promise a friendly assistance.