LLMS_Privacy::get_student_enrollments( LLMS_Student $student, int $page, string $post_type )
Retrieve student course & membership enrollment data
Parameters Parameters
- $student
-
(LLMS_Student) (Required) Student object.
- $page
-
(int) (Required) Page number.
- $post_type
-
(string) (Required) WP Post type (course/membership).
Return Return
(array)
Source Source
File: includes/privacy/class-llms-privacy.php
protected static function get_student_enrollments( $student, $page, $post_type ) { $limit = 250; $enrollments = $student->get_enrollments( $post_type, array( 'limit' => $limit, 'skip' => ( $page - 1 ) * $limit, ) ); return array( 'done' => ( ! $enrollments['more'] ), 'results' => $enrollments['results'], ); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
3.18.0 | Introduced. |