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.
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
LD_LESSONDONE::course_matches( int $field_course_id, int $action_hook_course_id )
Determine if the selected course in the trigger matches the one sent by the action hook.
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Parameters Parameters
- $field_course_id
(Required) The course ID from the field.
- $action_hook_course_id
(Required) The course ID sent from 'learndash_lesson_completed'.
Return Return
(bool) True if course matches. Otherwise, false.
Source Source
File: src/integrations/learndash/triggers/ld-lessondone.php
private function course_matches( $field_course_id = 0, $action_hook_course_id = 0 ) { // Determine if selected course matches from received course ID. $course_is_any = intval( $field_course_id ) === -1; $course_matches = intval( $field_course_id ) === intval( $action_hook_course_id ) || $course_is_any; return $course_matches; }
Expand full source code Collapse full source code View on Github