Hi Dana. Thanks for the great question.
There are several ways you could do this.
1. If you are only sending this to paid Members, you can use the Replacement Code
%%subscr_id%% in your Signup Confirmation Email. This is documented in your WP Dashboard, under:
s2Member -> PayPal Options -> Signup Confirmation Email2. Or, you could also use one of the Custom Replacement Codes ( %%cv1%% ) perhaps. Also documented under:
s2Member -> PayPal Options -> Signup Confirmation Email3. You could access information about a Member with Hooks/Filters; working in conjunction with the actual Registration process; which would provide compatibility with Free Registrations, and not just paid transactions. Here is sample code snippet that might help you, or your developer:
Place something like this inside the functions.php file for your WordPress theme:
- Code: Select all
<?php
add_action("ws_plugin__s2member_during_configure_user_registration", "my_function");
function my_function($vars){
$unique_user_id = $vars["user_id"];
// print_r($vars); to get a full list for testing.
}
?>
4. You could also use s2Member's API Notifications. These are dispatched automatically; based on specific events within the s2Member Framework. Check your WP Dashboard, under:
s2Member -> API Notifications@C/TODO :: In a future release, we need to include the User ID as a Replacement Code for confirmation emails; and anywhere else it may be applicable. This would also be useful in this scenario.