llms_delete_student_enrollment( int $user_id, int $product_id, string $trigger = 'any' )

Delete LifterLMS Student’s Enrollment record related to a given product.


Description Description

See also See also

  • `LLMS_Student->delete_enrollment()`: the class method wrapped by this function.

Top ↑

Parameters Parameters

$user_id

(Required) WP User ID.

$product_id

(Required) WP Post ID of the Course or Membership.

$trigger

(Optional) Only delete the student enrollment if the original enrollment trigger matches the submitted value. Passing "any" will remove regardless of enrollment trigger.

Default value: 'any'


Top ↑

Return Return

(boolean) Whether or not the enrollment records have been successfully removed.


Top ↑

Source Source

File: includes/functions/llms.functions.person.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
3.33.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.