llms_enroll_student( int $user_id, int $product_id, string $trigger = 'unspecified' )
Enroll a WordPress user in a course or membership
Description Description
See also See also
- LLMS_Student->enroll(): the class method wrapped by this function
Parameters Parameters
- $user_id
-
(Required) WP User ID.
- $product_id
-
(Required) WP Post ID of the Course or Membership.
- $trigger
-
(Optional) String describing the event that triggered the enrollment.
Default value: 'unspecified'
Return Return
(boolean)
Source Source
File: includes/functions/llms.functions.person.php
Changelog Changelog
Version | Description |
---|---|
3.0.0 | Added $trigger parameter. |
2.2.3 | Introduced. |