get_contact_id()

get_contact_id()

#Overview
This function retrieves a user』s CRM contact ID based on their WordPress user ID.
#Get the current user』s contact ID
$contact_id = wpf_get_contact_id();
#Get the contact ID for a different user
$contact_id = wpf_get_contact_id( $user_id );
#Force an update of the user』s contact ID by sending an API call to your CRM
In this case the updated contact ID will automatically be saved to the local user meta after it』s been retrieved.
$contact_id = wpf_get_contact_id( $user_id, true );

#Was this helpful?

Let us know if you liked the post. That』s the only way we can improve.

Yes

No

發表回覆

您的郵箱地址不會被公開。 必填項已用 * 標註