Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Add a filter to allow filtering of profile fields per membership level. #142

Open
ipokkel opened this issue May 4, 2023 · 1 comment

Comments

@ipokkel
Copy link
Member

ipokkel commented May 4, 2023

There are a few shortcode attributes, e.g. show_name, show_avatar, etc. The ability to show or hide/remove some of these conditionally per membership level or user id could be helpful.

For example:
When the profile of a level 1 member is displayed only their avatar and name but none of the others, a profile of a level 2 member shows their address as well, and a profile of a level 3 member shows their URL.

$pmpro_member_profile_show = apply_filters( 'pmpro_member_profile_show', $pmpro_member_profile_show_array, $pu );

@ipokkel ipokkel changed the title Feature: Add a filter to Feature: Add a filter to allow filtering of profile fields per membership level. May 4, 2023
@ipokkel
Copy link
Member Author

ipokkel commented May 4, 2023

As an experimental proof of concept example see https://gist.github.com/ipokkel/f48eaa18889146ad67fb9be73eb4e720

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants