コード例 #1
0
/**
 * Register our users' custom taxonomies.
 *
 * @since 0.5.0
 *
 * @internal
 */
function cptui_create_custom_taxonomies()
{
    $taxes = get_option('cptui_taxonomies');
    if (empty($taxes)) {
        return;
    }
    /**
     * Fires before the start of the taxonomy registrations.
     *
     * @since 1.3.0
     *
     * @param array $taxes Array of taxonomies to register.
     */
    do_action('cptui_pre_register_taxonomies', $taxes);
    if (is_array($taxes)) {
        foreach ($taxes as $tax) {
            cptui_register_single_taxonomy($tax);
        }
    }
    /**
     * Fires after the completion of the taxonomy registrations.
     *
     * @since 1.3.0
     *
     * @param array $taxes Array of taxonomies registered.
     */
    do_action('cptui_post_register_taxonomies', $taxes);
}
コード例 #2
0
/**
 * Register our users' custom taxonomies.
 *
 * @since 0.5.0
 */
function cptui_create_custom_taxonomies()
{
    $taxes = get_option('cptui_taxonomies');
    if (is_array($taxes)) {
        foreach ($taxes as $tax) {
            cptui_register_single_taxonomy($tax);
        }
    }
}
コード例 #3
0
 public function register_taxonomy()
 {
     cptui_register_single_taxonomy($this->taxonomy_array['actors']);
 }