Allow site visitors to connect through a basic contact form on a member’s profile listing. When someone views a directory profile, they will see a form that automatically sends to the individual profile user’s email address. This can be a major feature for some listing sites, that want to enhance networking, referrals, or lead generation for their members.
The recipe below uses the popular Contact Form 7 plugin for WordPress and our Member Directory and Profile Pages Add On.
Table of contents
The Code Recipe
Adding the Recipe to Your Website
You can add this recipe to your site by creating a custom plugin or using the Code Snippets plugin, available for free in the WordPress repository. Read this companion article for step-by-step directions on either method.
Want to tweak this recipe? An AI coding assistant can help you adjust the code to fit your exact needs, or even add it to your site for you. Always test changes on a staging site first and keep a backup.
Rather have us handle it? With PMPro Max, you can submit a Do It For Me request, and our team will review it and, when possible, add or customize this recipe directly on your site.
Edit the Recipe and Contact Forms
There are three specific steps to make this recipe work for your site:
- Update line 49 with the correct shortcode for your desired form to display.
- Add this hidden field to your form directly before the submit button:
[hidden send-to-email default:shortcode_attr].
Settings page screenshot with the hidden “send-to-email” field on the contact form. - Update the form’s “To” field of the contact form’s email to “[send-to-email]”. The form will not display when the current user is viewing their own profile.

Add the shortcode to swap in on the “Email” field. - Note that if the email being sent through the form is formatted a plain text, you can check the box “Use HTML content type” under the Mail > Message Body setting in Contact Form 7.
Screenshot

Get Support From Our Team of Experts
Have a question about how to use this feature? Our Support Page outlines three ways to get support.
Our Max plans include hands-on help customizing your membership site and implementing new features. Upgrade to PMPro Max now »


