Taxonomies

Taxonomies helper class.

Tags
author

Barn2 Plugins support@barn2.com

license

GPL-3.0

copyright

Barn2 Media Ltd

Table of Contents

get_default_excluded_terms()  : array<string|int, mixed>
Get the list of default excluded terms that should not be displayed inside filters.
get_registered_attributes()  : array<string|int, mixed>
Get the list of all global attributes taxonomies.
get_registered_taxonomies()  : array<string|int, mixed>
Get a list of registered taxonomies for products excluding a certain subset.

Methods

get_default_excluded_terms()

Get the list of default excluded terms that should not be displayed inside filters.

public static get_default_excluded_terms(string $taxonomy) : array<string|int, mixed>
Parameters
$taxonomy : string
Return values
array<string|int, mixed>

get_registered_attributes()

Get the list of all global attributes taxonomies.

public static get_registered_attributes([bool $with_prefix = false ]) : array<string|int, mixed>
Parameters
$with_prefix : bool = false

whether we need the "pa_" prefix in front of the name.

Return values
array<string|int, mixed>

get_registered_taxonomies()

Get a list of registered taxonomies for products excluding a certain subset.

public static get_registered_taxonomies([bool $exclude_default = false ][, bool $with_attributes = false ]) : array<string|int, mixed>
Parameters
$exclude_default : bool = false

when true, it will exclude categories and tags too.

$with_attributes : bool = false

when true, it will include attributes too.

Return values
array<string|int, mixed>

Search results