Alert: This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.
LLMS_Privacy_Exporters::get_certificate_data( LLMS_User_Certificate $cert )
Get data for a certificate.
Parameters Parameters
- $cert
-
(LLMS_User_Certificate) (Required) Certificate object.
Return Return
(array)
Source Source
File: includes/privacy/class-llms-privacy-exporters.php
private static function get_certificate_data( $cert ) { $data = array(); $title = $cert->get( 'title' ); $filename = llms()->certificates()->get_export( $cert->get( 'id' ), true ); if ( ! is_wp_error( $filename ) ) { $title = '<a href="certificates/' . basename( $filename ) . '">' . $title . '</a>'; } $data[] = array( 'name' => __( 'Title', 'lifterlms' ), 'value' => $title, ); $data[] = array( 'name' => __( 'Earned Date', 'lifterlms' ), 'value' => $cert->get_earned_date( 'Y-m-d H:i:s' ), ); return $data; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
6.0.0 | Replaced the use of the deprecated certificate_title meta key with the post's title property. |
3.18.0 | Introduced. |