apply_filters( 'learndash_certificate_immage_type', string $type, int $post_id, int $thumbnail_id )
Filters the type of the image to use for the certificate PDF background.
Contents
Description #
Filter to allow URLs to be used for certificate background images. LEARNDASH-3430
Parameters #
- $type
-
(string) Default 'path' will user local server path. 'url' will use image URL.
- $post_id
-
(int) Post ID of certificate to be shown.
- $thumbnail_id
-
(int) Image thumbnail ID.
Source #
Examples #
Note: Extended code example below not guaranteed, you may need to consult with a developer
<?php /** * Example usage for learndash_certificate_immage_type filter. */ add_filter( 'learndash_certificate_immage_type', function( $type, $post_id, $thumbnail_id ) { // May add any custom logic using $type, $post_id, $thumbnail_id. // Always return $type. return $type; }, 10, 3 );
Changelog #
Version | Description |
---|---|
3.2.0 | Introduced. |