lifterlms_template_student_dashboard_my_achievements( bool $preview = false )
Template for My Achievements on dashboard
Parameters Parameters
- $preview
-
(bool) (Optional) If
true
, outputs a short list of achievements to display on the dashboard landing page. Otherwise displays all of the earned achievements for display on the view-achievements endpoint.Default value: false
Return Return
(void)
Source Source
File: includes/functions/llms.functions.templates.dashboard.php
* @param LLMS_Student $student Optional. LLMS_Student (current student if none supplied). Default `null`. * @return void */ function lifterlms_template_my_memberships_loop( $student = null ) { $student = llms_get_student( $student ); if ( ! $student ) { return; } $memberships = $student->get_membership_levels(); if ( ! $memberships ) { printf( '<p>%s</p>', /** * Not enrolled text. * * Allows developers to filter the text to be displayed when the student is not enrolled in any memberships. * * @since 7.1.3 * * @param string $not_enrolled_text The text to be displayed when the student is not enrolled in any memberships. */ apply_filters( 'lifterlms_dashboard_memberships_not_enrolled_text', esc_html__( 'You are not enrolled in any memberships.', 'lifterlms' ) ) ); } else { add_action( 'lifterlms_after_loop_item_title', 'lifterlms_template_loop_enroll_status', 25 ); add_action( 'lifterlms_after_loop_item_title', 'lifterlms_template_loop_enroll_date', 30 ); $query = new WP_Query( array( 'orderby' => 'title',
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
6.0.0 | Don't output HTML when the endpoint is disabled. |
3.19.0 | Unknown. |
3.14.0 | Introduced. |