lifterlms_template_student_dashboard_my_grades_table( LLMS_Course $course, LLMS_Student $student )

Output the template for a single grades table on the student dashboard


Parameters Parameters

$course

(LLMS_Course) (Required) LLMS_Course.

$student

(LLMS_Student) (Required) LLMS_Student.


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/functions/llms.functions.templates.dashboard.php

	 * @since 3.26.3 Unknown.
	 * @since 5.3.2 Cast achievement_template ID to string when comparing to the list of achievement IDs related the course/membership (list of strings).
	 * @since 5.9.0 Stop using deprecated `FILTER_SANITIZE_STRING`.
	 * @since 6.0.0 Use updated method signature for `LLMS_Student::get_achievements()`.
	 * @since 6.3.0 Prevent trying to access to a non existing index when retrieving the slug from the `$wp_query`.
	 *              Fixed pagination not working when using plain permalinks.
	 * @return void
	 */
	function lifterlms_template_student_dashboard_my_grades() {

		$student = llms_get_student();
		if ( ! $student ) {
			return;
		}

		global $wp_query, $wp_rewrite;
		$slug = $wp_query->query['my-grades'] ?? '';

		// List courses.
		if ( empty( $slug ) || false !== strpos( $slug, $wp_rewrite->pagination_base . '/' ) ) {

			/**
			 * Filter the number of courses per pages to be displayed in my grades
			 *
			 * @since unknown
			 *
			 * @param int $per_page The number of courses per pages to be displayed. Default is `10`.


Top ↑

Changelog Changelog

Changelog
Version Description
3.24.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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