rcp_set_expiration_date()

rcp_set_expiration_date( $user_id = 0, $new_date = '' )

Use this function to set a new expiration date for a given user.

Parameters:

  • $user_id (int) (optional) - The ID of the user to set the expiration date for. Set to 0 to use the ID of the currently logged in user.
  • $new_date (string) - The new expiration date to set. This should be passed as a MySQL date string.

Return values:

  • true if the operation was successful.
  • false if the expiration date was not successfully updated.