PHPackages                             carloswph/ilk - 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. carloswph/ilk

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

carloswph/ilk
=============

Custom Post Type and Custom Taxonomies helper for Wordpress.

v1.0.6(4y ago)332MITPHP

Since Mar 11Pushed 4y ago1 watchersCompare

[ Source](https://github.com/carloswph/ilk)[ Packagist](https://packagist.org/packages/carloswph/ilk)[ RSS](/packages/carloswph-ilk/feed)WikiDiscussions main Synced 4w ago

READMEChangelog (8)Dependencies (1)Versions (8)Used By (0)

Ilk
===

[](#ilk)

[![Codacy Security Scan](https://github.com/carloswph/ilk/actions/workflows/codacy-analysis.yml/badge.svg)](https://github.com/carloswph/ilk/actions/workflows/codacy-analysis.yml)

Custom post types and custom taxonomies - one of the must-haves for any WP developer or web designers. They allow Wordpress websites to be turned into platforms, services and entire systems. There are thousands of ways of creating post types and taxonomies, and also a number of helper classes and wrappers. So, why do we need yet another?

Most post type helpers have something in common: they are not maintained. With Ilk, we come with a different proposal - to keep things always up-to-date, considering WP core, and launch new features and tools frequently.

Installation
============

[](#installation)

Using Composer, of course: `carloswph/ilk`, which is the recommended way.

But you can also clone this repo and require the classes files, located in the `src/`folder, or even autoloading yourself, depending on the script you are using.

Usage
=====

[](#usage)

Yeah, we really try to keep things neat and simple. Ilk uses an Illuminati class named Pluralize, which allows you to submit just the singular post type (or taxonomy) name, and the script finds the equivalent plural in English. Perhaps we add some other languages in the future.

Regarding the logic, it is again pretty simple. All you need to do to create a new post type is instancing the Builder class, with the singular post type name:

```
$cpt = new Builder('Foot'); // The plural 'Feet' is automatically found and generated

$cpt->enableRest(); // If you want the post type to show in rest (default is false)
$cpt->setSupports('excerpt'); // If you want to add any new feature support
$cpt->setI18n('ilk-rulez'); // Sets a slug for translations, if necessary
```

Other class, TermBuilder, will allow you to create custom taxonomies for those post types you have just built. Logic, again, is quite simple: instatiating the class, using the singular name of the desired taxonomy as first argument and the custom post type class instance as second.

```
$tax = new TermBuilder('Knife', $cpt); // Again, the plural 'Knives' will be automatically managed

$tax->enableRest(); // Same logic as CPTs
$tax->likeCategory(); // Taxonomies are by default non-hierarchical, but you can make them hierarchical using this method
```

Other methods
-------------

[](#other-methods)

Some other methods can be used. Commonly, we want the new post type menu to appear as submenu in a particular part of the backend. Sometimes, yet, we don't even want a menu to be shown. Both situations can be addressed with this method:

```
$cpt->setMenu(false); // No post type in backend menu
$cpt->setMenu('options-general.php'); // Post type as submenu for Settings
```

Also, as feature supports can be added anytime, they could be also removed, by using the following method:

```
$cpt->dropSupports('excerpt');
```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 55% of commits — single point of failure

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

Every ~43 days

Recently: every ~65 days

Total

7

Last Release

1624d ago

Major Versions

0.1-alpha → v1.0.02021-03-11

### Community

Maintainers

![](https://www.gravatar.com/avatar/13c91dcf5209989038da335ba42538fa84670bf27400f220d182a76e0a720b74?d=identicon)[carloswph](/maintainers/carloswph)

---

Top Contributors

[![meuppt](https://avatars.githubusercontent.com/u/37983141?v=4)](https://github.com/meuppt "meuppt (11 commits)")[![carloswph](https://avatars.githubusercontent.com/u/78516217?v=4)](https://github.com/carloswph "carloswph (9 commits)")

---

Tags

wordpresscustom-post-typecptpost typewordpress helpercpt helpercustom post type helper

### Embed Badge

![Health badge](/badges/carloswph-ilk/health.svg)

```
[![Health](https://phpackages.com/badges/carloswph-ilk/health.svg)](https://phpackages.com/packages/carloswph-ilk)
```

###  Alternatives

[log1x/poet

Configuration-based post type, taxonomy, editor color palette, block category, and block registration for Sage 10.

218280.1k1](/packages/log1x-poet)[php-stubs/wordpress-stubs

WordPress function and class declaration stubs for static analysis.

19013.0M261](/packages/php-stubs-wordpress-stubs)[wpbp/cpt_columns

Improve the CPT list in the backend for your CPTs

218.3k](/packages/wpbp-cpt-columns)

PHPackages © 2026

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