Paidmembershipspro
Day 34 after signup
Tooltip Tuesday: Fields members can see but only admins can edit
Plus a no-code option for showing members information they can’t change.
Why it works
- Explain the problem and the recipe’s core behavior before walking readers through code changes.
- Use a concrete example to make technical steps easier to understand, then show how to test the result from both user perspectives.
- Keep related resources and upcoming events after the main tutorial so the educational content stays central.
How it is built
- Personal greeting
- Recipe overview
- Role distinction
- Customization steps
Email copy
Hey [First name], On Friday, November 6, Coding with Sam covered a recipe that fills a common gap in User Fields. By default, a field shows the same type to everyone, so a field a member sees on their profile is usually one they can edit too. This recipe changes the field type based on who is viewing it. Administrators get an editable field, and everyone else sees the same information as read-only text. Before opening the code, Sam explained the difference between WordPress roles and membership levels, since this recipe relies on roles. A user’s role controls what they can do in your WordPress site. Their membership level controls what content they can access. Most members have the Subscriber role. Kim added that PMPro has kept roles and levels separate from the start, so most sites never need to touch roles at all. This recipe checks whether a user has the manage_options capability, which administrators have, and changes the field type based on that. Swapping in Your Own Field The recipe uses a member number as its example. Sam mentioned that her dad’s metal detecting site uses member numbers this way. For the demo, she swapped in a birthday instead. A birthday shouldn’t change once it’s set, but an admin might need to fix it if a member makes a mistake. That matters even more if your site has age requirements. Sam made three small changes along the way. She changed the admin’s field type from text to date, which gives admins a calendar picker. She updated the field name and the label, explaining that the name is how the value is stored with the member’s data, and the label is what members see on their profile. She also renamed the field group from “Member Details” to “Personal Information.” One step is easy to miss. This recipe creates the field itself, so Sam deleted the one she had started in the User Fields settings. If you already have a field there with the same name, remove it before adding the snippet. To test it, Sam added a birthday to a demo member’s profile and switched to that member’s account. On their Edit Profile page, the birthday showed as plain text with no way to change it. Back in her own admin account, the same field was an editable date field. If members don’t need to see the field on their profile, there’s a no-code option. Kim suggested setting it up as an admin-only field and using the [pmpro_member] shortcode to show its value on a page. That works well for something like a coach writing a custom plan for each member. You fill it in on the member’s profile in the admin, and they see it as text on the front end. If you’d like help setting this up for your own site, PMPro Max includes hands-on help customizing your membership site. Watch the Episode Get the Code What's Next? Coding with Sam: Control When Renew Link Appears on Account Page, Friday, November 20 at 9am ET: The “Renew” link on the Membership Account page is tied to each level’s billing period, so annual members can see it all year while members on shorter periods might barely see it before it disappears. Sam shows how to set one renewal window, so the link appears the same number of days before expiration for every level. Coding with Sam: Allow Public Access to Individual Posts in a Protected Category, Friday, December 4 at 9am ET: Follow along as Sam adds a recipe that puts an Access Override checkbox in the post editor. Check it, and that one post becomes public while the rest of the category stays protected. It uses the pmpro_has_membership_access_filter filter, so it works with PMPro’s existing access rules. Open Office Hours: Build Challenge: Kim vs. Sam, Thursday, December 10 at 11am ET: Kim Coleman and Sam Daugherty each race the clock to build a membership site page, live. Kim White hosts. Watch two different approaches to the same challenge and pick up page-building moves you can use on your own site. Hope to see you at one of these events soon! Happy coding, — Kristy Sutton, Marketing Coordinator, Paid Membersh