wpmem_get_user_expiration()

Description

Retrieves the expiration date of a membership for a user.

Parameters

$product
(mixed) (optional) The meta key of the product being checked, or an array of product meta keys. If no product key is passed, it defaults to the first membership in the array.

$user_id
(integer) (optional) The user ID to check. If no user ID is passed, it will check for the currently logged in user.

Return Value

boolean (string) Returns an unformatted epoch timestamp for the user’s expiration date.

Changelog

Introduced in version 3.4.2

Source

wpmem_get_user_expiration() is located in /includes/api/api-users.php.