LLMS_Student::get_last_completed_lesson( int $course_id )

Get the students last completed lesson in a course


Parameters Parameters

$course_id

(int) (Required) WP_Post ID of the course


Top ↑

Return Return

(int) WP_Post ID of the lesson or false if no progress has been made


Top ↑

Source Source

File: includes/models/model.llms.student.php

				array_push( $progresses, $this->get_progress( $course_id, 'course' ) );
			}

			$count = count( $progresses );
			if ( $count ) {

				$progress = round( array_sum( $progresses ) / $count, 2 );

			} else {

				$progress = 0;

			}



Top ↑

Changelog Changelog

Changelog
Version Description
3.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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