PHPackages                             flexpress/component-taxonomy - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. flexpress/component-taxonomy

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

flexpress/component-taxonomy
============================

Taxonomy helper for WordPress

v1.0.0(11y ago)0951PHP

Since Aug 13Pushed 11y ago1 watchersCompare

[ Source](https://github.com/FlexPress/component-taxonomy)[ Packagist](https://packagist.org/packages/flexpress/component-taxonomy)[ RSS](/packages/flexpress-component-taxonomy/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (2)Used By (1)

FlexPress taxonomy component
============================

[](#flexpress-taxonomy-component)

Install with Pimple
-------------------

[](#install-with-pimple)

The taxonomy component uses two classes:

- AbstractTaxonommy, which you extend to create a taxonomy.
- TaxonomyHelper, which hooks into everything for you and registers the taxonomies.

Lets create a pimple config for both of these

```
$pimple["documentTypeTaxonomy"] = function () {
  return new DocumentType();
};

$pimple['taxonomyHelper'] = function ($c) {
    return new TaxonomyHelper($c['objectStorage'], array(
        $c["documentTypeTaxonomy"]
    ));
};

```

- Note the dependency $c\['objectStorage'\] is a SPLObjectStorage

Creating a concreate Taxonomy class
-----------------------------------

[](#creating-a-concreate-taxonomy-class)

Create a concreate class that implements the AbstractTaxonomy class and implements the getName() and getSupportedPostTypes() methods.

```
class DocumentType extends AbstractTaxonomy {

    public function getName()
    {
      return "document-type";
    }

    public function getSupportedPostTypes()
    {
      return array("document");
    }

}

```

This above example is the bare minimum you must implement, the example that follows is the other extreme implementing all available methods.

```
class DocumentType extends AbstractTaxonomy {

  public function getName()
  {
    return "document-type";
  }

  public function getSupportedPostTypes()
  {
    return array("document");
  }

  protected function getLabels()
  {
    $labels = parent::getLabels();
    $labels['menu_name'] = 'Type';
    return $labels;
  }

  public function getArgs()
  {
    $args = parent::getArgs();
    $args['query_var'] = false;
    return $args;
  }

  public function getPluralName()
  {
    return "Doc types";
  }

  public function getSingularName()
  {
    return "Doc type";
  }

}

```

### Public Methods

[](#public-methods)

- getSingularName() - returns the singular name of the taxonomy.
- getPluralName() - returns the plural name of the taxonomy.
- getArgs() - returns the array of args.
- getLabels() - Returns the array of labels.
- getName() - Returns taxonomy name.
- getSupportedPostTypes() - Return an array of post types the taxonomy should be attached to.

TaxonomyHelper usage
--------------------

[](#taxonomyhelper-usage)

Once you have setup the pimple config you are use the TaxonomyHelper like this

```
$helper = $pimple['taxonomyHelper'];
$helper->registerTaxonomies();

```

That's it, the helper will then add all the needed hooks and register all the taxonomies you have provided it.

### Public methods

[](#public-methods-1)

- registerTaxonomies() - Registers the taxonomies provided.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity63

Established project with proven stability

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

4296d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2b794650fae4ab8d86e8550fa2e0cd8658323e07a8d78b3e96d0bc373bc88d2a?d=identicon)[timperry](/maintainers/timperry)

### Embed Badge

![Health badge](/badges/flexpress-component-taxonomy/health.svg)

```
[![Health](https://phpackages.com/badges/flexpress-component-taxonomy/health.svg)](https://phpackages.com/packages/flexpress-component-taxonomy)
```

###  Alternatives

[artisaninweb/laravel-soap

A SoapClient wrapper integration for Laravel

6314.5M12](/packages/artisaninweb-laravel-soap)[valentin-morice/filament-json-column

A simple package to view and edit your JSON columns in Filament

59431.3k](/packages/valentin-morice-filament-json-column)[easycorp/easy-doc-bundle

Symfony application documentation generator

1031.0k](/packages/easycorp-easy-doc-bundle)[miracuthbert/laravel-multi-tenancy

A single database and multi-database multi-tenancy package for Laravel 5.8 and up

161.6k](/packages/miracuthbert-laravel-multi-tenancy)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
