Skip to main content

Group Hooks

Use these hooks to customize group grids, single-group templates, group access checks, cohort labels, and subgroup branding.

Only custom MentorKit hooks from docs-lms/hook-metadata.json are documented here. Classic WordPress, WooCommerce, Polylang, Astra, and other external hooks are intentionally excluded.

Documented hooks: 41.

Documented Hooks

HookTypeStatus
scorm_after_group_actionsActionPublic
scorm_after_group_cardActionPublic
scorm_after_group_card_actionsActionPublic
scorm_after_group_card_contentActionPublic
scorm_after_group_card_mediaActionPublic
scorm_after_group_card_metaActionPublic
scorm_after_group_contentActionPublic
scorm_after_group_coursesActionPublic
scorm_after_group_infoActionPublic
scorm_after_group_mediaActionPublic
scorm_after_group_statisticsActionPublic
scorm_after_groups_gridActionPublic
scorm_after_groups_grid_loopActionPublic
scorm_after_groups_grid_paginationActionPublic
scorm_after_groups_grid_queryActionPublic
scorm_after_single_groupActionPublic
scorm_after_single_group_headerActionPublic
scorm_before_group_actionsActionPublic
scorm_before_group_cardActionPublic
scorm_before_group_card_actionsActionPublic
scorm_before_group_card_contentActionPublic
scorm_before_group_card_mediaActionPublic
scorm_before_group_card_metaActionPublic
scorm_before_group_contentActionPublic
scorm_before_group_coursesActionPublic
scorm_before_group_infoActionPublic
scorm_before_group_mediaActionPublic
scorm_before_group_statisticsActionPublic
scorm_before_groups_gridActionPublic
scorm_before_groups_grid_loopActionPublic
scorm_before_groups_grid_paginationActionPublic
scorm_before_single_groupActionPublic
scorm_before_single_group_headerActionPublic
scorm_group_card_classesFilterPublic
scorm_group_completion_labelFilterPublic
scorm_group_email_allowedFilterPublic
scorm_group_format_labelFilterPublic
scorm_group_module_metaFilterPublic
scorm_groups_grid_query_argsFilterPublic
scorm_player_customer_groups_enabledFilterPublic
scorm_subgroup_brandingFilterPublic

scorm_after_group_actions

Type: Action Category: Group Source: templates/single-scorm_group.php:322 Status: Public

When It Runs

Fires after group actions. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.
$scorm_wc_product$scorm_wc_productAdditional context passed by the hook.
$reserved_7''Additional context passed by the hook.
$reserved_8nullAdditional context passed by the hook.
$scorm_seats_remaining$scorm_seats_remainingAdditional context passed by the hook.
$is_available! $scorm_cta['disabled']Additional context passed by the hook.

Example

add_action(
'scorm_after_group_actions',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access, $scorm_wc_product, $reserved_7, $reserved_8, $scorm_seats_remaining, $is_available ) {
// Add your integration logic here.
},
10,
10
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_after_group_card

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:161, includes/frontend/groups-grid-shortcode.php:510 Status: Public

When It Runs

Fires after group card. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid(). This hook appears in 2 source locations.

Parameters

This hook is called from multiple source locations with different source signatures.

SourceCallback parameters
includes/frontend/groups-grid-shortcode.php:161$group_id from get_the_ID()
$grid_id from $grid_id
$attributes from $attributes
includes/frontend/groups-grid-shortcode.php:510$group_id from $group_id
$post from $post
$group_access from $group_access
$user_enrolled from $user_enrolled
$wc_product from $wc_product

Example

add_action(
'scorm_after_group_card',
function ( $group_id, $grid_id, $attributes ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Because the source signatures differ, write callbacks defensively when attaching the same callback across all contexts.
  • Parameter names vary between call sites.

scorm_after_group_card_actions

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:505 Status: Public

When It Runs

Fires after group card actions. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$wc_product$wc_productAdditional context passed by the hook.
$group_date_status$group_date_statusAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_card_actions',
function ( $group_id, $post, $user_enrolled, $group_access, $wc_product, $group_date_status ) {
// Add your integration logic here.
},
10,
6
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_card_content

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:507 Status: Public

When It Runs

Fires after group card content. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_card_content',
function ( $group_id, $post, $group_access, $user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_card_media

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:361 Status: Public

When It Runs

Fires after group card media. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_card_media',
function ( $group_id, $post, $group_access, $user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_card_meta

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:403 Status: Public

When It Runs

Fires after group card meta. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$show_course_count$show_course_countAdditional context passed by the hook.
$show_seats$show_seatsAdditional context passed by the hook.
$show_access$show_accessAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$wc_product$wc_productAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_card_meta',
function ( $group_id, $post, $show_course_count, $show_seats, $show_access, $group_access, $wc_product ) {
// Add your integration logic here.
},
10,
7
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_content

Type: Action Category: Group Source: templates/single-scorm_group.php:567 Status: Public

When It Runs

Fires after group content. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_content',
function ( $scorm_group_id, $post ) {
// Add your integration logic here.
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_courses

Type: Action Category: Group Source: templates/single-scorm_group.php:516 Status: Public

When It Runs

Fires after group courses. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_courses$scorm_coursesAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_courses',
function ( $scorm_group_id, $post, $scorm_courses, $scorm_user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_info

Type: Action Category: Group Source: templates/single-scorm_group.php:324 Status: Public

When It Runs

Fires after group info. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_info',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access ) {
// Add your integration logic here.
},
10,
5
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_after_group_media

Type: Action Category: Group Source: templates/single-scorm_group.php:348 Status: Public

When It Runs

Fires after group media. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_media',
function ( $scorm_group_id, $post ) {
// Add your integration logic here.
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_group_statistics

Type: Action Category: Group Source: templates/single-scorm_group.php:563 Status: Public

When It Runs

Fires after group statistics. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_courses$scorm_coursesAdditional context passed by the hook.
$scorm_enrollment_count$scorm_enrollment_countAdditional context passed by the hook.
$scorm_seats$scorm_seatsAdditional context passed by the hook.
$scorm_seats_remaining$scorm_seats_remainingAdditional context passed by the hook.

Example

add_action(
'scorm_after_group_statistics',
function ( $scorm_group_id, $post, $scorm_courses, $scorm_enrollment_count, $scorm_seats, $scorm_seats_remaining ) {
// Add your integration logic here.
},
10,
6
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_groups_grid

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:189 Status: Public

When It Runs

Fires after groups grid. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_after_groups_grid',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_groups_grid_loop

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:163 Status: Public

When It Runs

Fires after groups grid loop. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_after_groups_grid_loop',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_groups_grid_pagination

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:186 Status: Public

When It Runs

Fires after groups grid pagination. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_after_groups_grid_pagination',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_groups_grid_query

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:138 Status: Public

When It Runs

Fires after groups grid query. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$groups_query$groups_queryAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.

Example

add_action(
'scorm_after_groups_grid_query',
function ( $groups_query, $attributes ) {
// Add your integration logic here.
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_after_single_group

Type: Action Category: Group Source: templates/single-scorm_group.php:571 Status: Public

When It Runs

Fires after single group. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.

Example

add_action(
'scorm_after_single_group',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access ) {
// Add your integration logic here.
},
10,
5
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_after_single_group_header

Type: Action Category: Group Source: templates/single-scorm_group.php:352 Status: Public

When It Runs

Fires after single group header. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.

Example

add_action(
'scorm_after_single_group_header',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access ) {
// Add your integration logic here.
},
10,
5
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_before_group_actions

Type: Action Category: Group Source: templates/single-scorm_group.php:191 Status: Public

When It Runs

Fires before group actions. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.
$scorm_wc_product$scorm_wc_productAdditional context passed by the hook.
$reserved_7''Additional context passed by the hook.
$reserved_8nullAdditional context passed by the hook.
$scorm_seats_remaining$scorm_seats_remainingAdditional context passed by the hook.
$is_available! $scorm_cta['disabled']Additional context passed by the hook.

Example

add_action(
'scorm_before_group_actions',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access, $scorm_wc_product, $reserved_7, $reserved_8, $scorm_seats_remaining, $is_available ) {
// Add your integration logic here.
},
10,
10
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_before_group_card

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:159, includes/frontend/groups-grid-shortcode.php:309 Status: Public

When It Runs

Fires before group card. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid(). This hook appears in 2 source locations.

Parameters

This hook is called from multiple source locations with different source signatures.

SourceCallback parameters
includes/frontend/groups-grid-shortcode.php:159$group_id from get_the_ID()
$grid_id from $grid_id
$attributes from $attributes
includes/frontend/groups-grid-shortcode.php:309$group_id from $group_id
$post from $post
$group_access from $group_access
$user_enrolled from $user_enrolled
$wc_product from $wc_product

Example

add_action(
'scorm_before_group_card',
function ( $group_id, $grid_id, $attributes ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Because the source signatures differ, write callbacks defensively when attaching the same callback across all contexts.
  • Parameter names vary between call sites.

scorm_before_group_card_actions

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:435 Status: Public

When It Runs

Fires before group card actions. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$wc_product$wc_productAdditional context passed by the hook.
$group_date_status$group_date_statusAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_card_actions',
function ( $group_id, $post, $user_enrolled, $group_access, $wc_product, $group_date_status ) {
// Add your integration logic here.
},
10,
6
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_card_content

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:363 Status: Public

When It Runs

Fires before group card content. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_card_content',
function ( $group_id, $post, $group_access, $user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_card_media

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:331 Status: Public

When It Runs

Fires before group card media. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_card_media',
function ( $group_id, $post, $group_access, $user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_card_meta

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:369 Status: Public

When It Runs

Fires before group card meta. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$show_course_count$show_course_countAdditional context passed by the hook.
$show_seats$show_seatsAdditional context passed by the hook.
$show_access$show_accessAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$wc_product$wc_productAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_card_meta',
function ( $group_id, $post, $show_course_count, $show_seats, $show_access, $group_access, $wc_product ) {
// Add your integration logic here.
},
10,
7
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_content

Type: Action Category: Group Source: templates/single-scorm_group.php:355 Status: Public

When It Runs

Fires before group content. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_content',
function ( $scorm_group_id, $post ) {
// Add your integration logic here.
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_courses

Type: Action Category: Group Source: templates/single-scorm_group.php:368 Status: Public

When It Runs

Fires before group courses. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_courses$scorm_coursesAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_courses',
function ( $scorm_group_id, $post, $scorm_courses, $scorm_user_enrolled ) {
// Add your integration logic here.
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_info

Type: Action Category: Group Source: templates/single-scorm_group.php:130 Status: Public

When It Runs

Fires before group info. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_info',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access ) {
// Add your integration logic here.
},
10,
5
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_before_group_media

Type: Action Category: Group Source: templates/single-scorm_group.php:327 Status: Public

When It Runs

Fires before group media. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_media',
function ( $scorm_group_id, $post ) {
// Add your integration logic here.
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_group_statistics

Type: Action Category: Group Source: templates/single-scorm_group.php:562 Status: Public

When It Runs

Fires before group statistics. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_courses$scorm_coursesAdditional context passed by the hook.
$scorm_enrollment_count$scorm_enrollment_countAdditional context passed by the hook.
$scorm_seats$scorm_seatsAdditional context passed by the hook.
$scorm_seats_remaining$scorm_seats_remainingAdditional context passed by the hook.

Example

add_action(
'scorm_before_group_statistics',
function ( $scorm_group_id, $post, $scorm_courses, $scorm_enrollment_count, $scorm_seats, $scorm_seats_remaining ) {
// Add your integration logic here.
},
10,
6
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_groups_grid

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:151 Status: Public

When It Runs

Fires before groups grid. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_before_groups_grid',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_groups_grid_loop

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:154 Status: Public

When It Runs

Fires before groups grid loop. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_before_groups_grid_loop',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_groups_grid_pagination

Type: Action Category: Group Source: includes/frontend/groups-grid-shortcode.php:167 Status: Public

When It Runs

Fires before groups grid pagination. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$grid_id$grid_idAdditional context passed by the hook.
$attributes$attributesAdditional context passed by the hook.
$groups_query$groups_queryAdditional context passed by the hook.

Example

add_action(
'scorm_before_groups_grid_pagination',
function ( $grid_id, $attributes, $groups_query ) {
// Add your integration logic here.
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_before_single_group

Type: Action Category: Group Source: templates/single-scorm_group.php:79 Status: Public

When It Runs

Fires before single group. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.
$scorm_wc_product$scorm_wc_productAdditional context passed by the hook.
$scorm_seats$scorm_seatsAdditional context passed by the hook.
$reserved_8nullAdditional context passed by the hook.
$scorm_seats_remaining$scorm_seats_remainingAdditional context passed by the hook.

Example

add_action(
'scorm_before_single_group',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access, $scorm_wc_product, $scorm_seats, $reserved_8, $scorm_seats_remaining ) {
// Add your integration logic here.
},
10,
9
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_before_single_group_header

Type: Action Category: Group Source: templates/single-scorm_group.php:125 Status: Public

When It Runs

Fires before single group header. The source call is inside templates/single-scorm_group.php.

Parameters

Callback parameterSource valueNotes
$scorm_group_id$scorm_group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$scorm_user_enrolled$scorm_user_enrolledAdditional context passed by the hook.
$reserved_4nullAdditional context passed by the hook.
$scorm_group_access$scorm_group_accessAdditional context passed by the hook.

Example

add_action(
'scorm_before_single_group_header',
function ( $scorm_group_id, $post, $scorm_user_enrolled, $reserved_4, $scorm_group_access ) {
// Add your integration logic here.
},
10,
5
);

Notes

  • Some source calls pass literal placeholder values; do not assume every argument is populated.

scorm_group_card_classes

Type: Filter Category: Group Source: includes/frontend/groups-grid-shortcode.php:318 Status: Public

When It Runs

Filters group card classes. The source call is inside SCORM_Groups_Grid_Shortcode::render_group_card().

Parameters

Callback parameterSource valueNotes
$classesarray('scorm-course-card', 'group-card', 'group-access-'. $group_access)Value passed through the filter. Source default: array('scorm-course-card', 'group-card', 'group-access-'. $group_access).
$group_id$group_idAdditional context passed by the hook.
$post$postAdditional context passed by the hook.
$group_access$group_accessAdditional context passed by the hook.
$user_enrolled$user_enrolledAdditional context passed by the hook.

Return Value

Return the filtered $classes value. Source default: array('scorm-course-card', 'group-card', 'group-access-'. $group_access). If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_group_card_classes',
function ( $classes, $group_id, $post, $group_access, $user_enrolled ) {
return $classes;
},
10,
5
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_group_completion_label

Type: Filter Category: Group Source: includes/frontend/group-helpers.php:836 Status: Public

When It Runs

Filters group completion label. The source call is inside scorm_player_group_completion_label(). Source context: Resolve the "Avslutning" label for a group's spec strip.

Parameters

Callback parameterSource valueNotes
$label''Value passed through the filter. Source default: ''.
$group_id$group_idAdditional context passed by the hook.

Return Value

Return the filtered $label value. Source default: ''. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_group_completion_label',
function ( $label, $group_id ) {
return $label;
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_group_email_allowed

Type: Filter Category: Group Source: includes/core/group-email-allowlist.php:118 Status: Public

When It Runs

Filters group email allowed. The source call is inside scorm_group_email_allowed(). Source context: Check whether an email address is allowed to join a given group based on the per-group domain allowlist.

Parameters

Callback parameterSource valueNotes
$decision$decisionValue passed through the filter. Source default: $decision.
$email$emailAdditional context passed by the hook.
$group_id(int) $group_idAdditional context passed by the hook.
$allowed_domains$allowed_domainsAdditional context passed by the hook.

Return Value

Return the filtered $decision value. Source default: $decision. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_group_email_allowed',
function ( $decision, $email, $group_id, $allowed_domains ) {
return $decision;
},
10,
4
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_group_format_label

Type: Filter Category: Group Source: includes/frontend/group-helpers.php:608 Status: Public

When It Runs

Filters group format label. The source call is inside scorm_player_group_format_label(). Source context: Resolve the "Format" label for a group's spec strip.

Parameters

Callback parameterSource valueNotes
$label''Value passed through the filter. Source default: ''.
$group_id$group_idAdditional context passed by the hook.
$courses$coursesAdditional context passed by the hook.

Return Value

Return the filtered $label value. Source default: ''. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_group_format_label',
function ( $label, $group_id, $courses ) {
return $label;
},
10,
3
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_group_module_meta

Type: Filter Category: Group Source: includes/frontend/group-path-render.php:50, templates/single-scorm_group.php:435 Status: Public

When It Runs

Filters group module meta. The source call is inside scorm_group_render_module_row(). Source context: Render one course as a group module row, reusing the existing.scorm-group-module-* markup so flat and sectioned lists look identical. This hook appears in 2 source locations.

Parameters

This hook is called from multiple source locations with different source signatures.

SourceCallback parameters
includes/frontend/group-path-render.php:50$meta_html from $meta_html
$course from $course
$group_id from $group_id
$status from $status
templates/single-scorm_group.php:435$scorm_default_meta from $scorm_default_meta
$scorm_course from $scorm_course
$scorm_group_id from $scorm_group_id
$scorm_module_status from $scorm_module_status

Return Value

Return the filtered $meta_html value. Source default: $meta_html. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_group_module_meta',
function ( $meta_html, $course, $group_id, $status ) {
return $meta_html;
},
10,
4
);

Notes

  • Because the source signatures differ, write callbacks defensively when attaching the same callback across all contexts.
  • Multiple default value expressions were found across filter call sites.
  • Parameter names vary between call sites.

scorm_groups_grid_query_args

Type: Filter Category: Group Source: includes/frontend/groups-grid-shortcode.php:132 Status: Public

When It Runs

Filters groups grid query args. The source call is inside SCORM_Groups_Grid_Shortcode::render_groups_grid().

Parameters

Callback parameterSource valueNotes
$query_args$query_argsValue passed through the filter. Source default: $query_args.
$attributes$attributesAdditional context passed by the hook.

Return Value

Return the filtered $query_args value. Source default: $query_args. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_groups_grid_query_args',
function ( $query_args, $attributes ) {
return $query_args;
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_player_customer_groups_enabled

Type: Filter Category: Group Source: includes/core/subgroup-inheritance.php:110 Status: Public

When It Runs

Filters customer groups enabled. The source call is inside scorm_player_customer_groups_enabled(). Source context: Is the sub-group feature enabled site-wide?

Parameters

Callback parameterSource valueNotes
$enabled'yes' === $settingValue passed through the filter. Source default: 'yes' === $setting.

Return Value

Return the filtered $enabled value. Source default: 'yes' === $setting. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_player_customer_groups_enabled',
function ( $enabled ) {
return $enabled;
},
10,
1
);

Notes

  • Keep callbacks small and scoped to the source context shown above.

scorm_subgroup_branding

Type: Filter Category: Group Source: includes/core/subgroup-inheritance.php:313 Status: Public

When It Runs

Filters subgroup branding. The source call is inside scorm_group_get_branding(). Source context: Get branding overrides for a group: logo attachment ID and accent colour.

Parameters

Callback parameterSource valueNotes
$branding$brandingValue passed through the filter. Source default: $branding.
$group_id$group_idAdditional context passed by the hook.

Return Value

Return the filtered $branding value. Source default: $branding. If you do not need to change it, return the original value unchanged.

Example

add_filter(
'scorm_subgroup_branding',
function ( $branding, $group_id ) {
return $branding;
},
10,
2
);

Notes

  • Keep callbacks small and scoped to the source context shown above.