Extracting meta key from Custom Fields

Hi all. I want to extract the meta key for a specific custom field from the registration form, to link with a an emailing plugin SendPress. When I exported the user information, the meta data for custom fields contains an array of data collected via the form. I want to isolate one item on that list. Any suggestions?

Hi Humphrey.

The s2 custom profile fields are saved as a serialized array in the usermeta row. You’ll need first to get the the field before using it in the email. You could try this: https://www.s2member.com/codex/stable/s2member/api_functions/package-functions/#src_doc_get_user_field()

<?php
$user_id = 234;
$my_field_data = get_user_field ('my_field_id', $user_id); # The Unique Field ID you configured with s2Member.
?>