# gamipress/7.9.8/integrations/tutor/includes/functions.php

GamiPress – Gamification plugin to reward points, badges &amp; ranks in WordPress, now with AI, version 7.9.8. 27 lines.

- Page: https://pluginprobe.com/plugins/gamipress/7.9.8/code/integrations/tutor/includes/functions.php
- Raw: https://pluginprobe.com/plugins/gamipress/7.9.8/raw/integrations/tutor/includes/functions.php
- Modified: 2026-07-13T13:39:46+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/gamipress/7.9.8/code/integrations/tutor/includes/functions.php#L10-L20`.

```php
<?php
/**
 * Functions
 *
 * @package GamiPress\LearnDash\Functions
 * @since 1.0.0
 */

// Exit if accessed directly
if( !defined( 'ABSPATH' ) ) exit;

/**
 * Retrieves post term ids for a taxonomy.
 *
 * @since  1.0.6
 *
 * @param  int    $post_id  Post ID.
 *
 * @return array
 */
function gamipress_tutor_get_term_ids( $course_id ) {

    $terms = get_the_terms( $course_id, 'course-category' );

    return ( empty( $terms ) || is_wp_error( $terms ) ) ? array() : wp_list_pluck( $terms, 'term_id' );

}
```
