PHPackages                             biont/wordpress-subplugins - 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. biont/wordpress-subplugins

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

biont/wordpress-subplugins
==========================

A library that allows you to add arbitrary new plugin pages to WordPress

1.0.1(10y ago)15691MITPHP

Since Feb 14Pushed 10y ago1 watchersCompare

[ Source](https://github.com/Biont/WordPress-SubPlugins)[ Packagist](https://packagist.org/packages/biont/wordpress-subplugins)[ Docs](https://github.com/Biont/WordPress-SubPlugins)[ RSS](/packages/biont-wordpress-subplugins/feed)WikiDiscussions master Synced today

READMEChangelog (1)DependenciesVersions (2)Used By (0)

WordPress-SubPlugins
====================

[](#wordpress-subplugins)

A library that allows you to add arbitrary new plugin pages to WordPress. You can use it to make your plugins more modular and allow users to turn features on and off as they wish

Example implementation
----------------------

[](#example-implementation)

This assumes the following folder structure:

```
   wp-content/plugins/my-plugin/my-plugin.php      - WordPress Plugin file
   wp-content/plugins/my-plugin/lib/sub-plugins    - SubPlugin library
   wp-content/plugins/my-plugin/plugins            - Subplugin folder

```

### wp-content/plugins/my-plugin/my-plugin.php

[](#wp-contentpluginsmy-pluginmy-pluginphp)

```
    /**
     * Plugin Name:    My Plugin
     * Description:    A demo plugin that has a cool sub-plugin feature!
     * Version:        1.0
     * Author:         Biont
     * Licence:        GPLv3
     * Text Domain:    my-textdomain
     * Domain Path:    /languages
     */

    include_once( plugin_dir_path( __FILE__ ) . 'lib/sub-plugins/sub-plugins.php' );

    $sub_plugin_folder = plugin_dir_path( __FILE__ ) . 'plugins';

    // This is used by all related options and for the sub-plugin files as well
    $prefix = 'biont';

    $plugin_args = array(
    	'menu_location' => 'index.php',                     // Where to show menu item
	    'page_title'    => __( 'Modules of My Plugin', 'my-textdomain' ),
	    'menu_title'    => __( 'RBP-Plugins', 'my-textdomain' ),
    );

    // Will show up under "Dashboard". See https://codex.wordpress.org/Function_Reference/add_submenu_page
    // for more information on where to put admin menu pages.
    add_subplugin_support( $sub_plugin_folder, $prefix, $plugin_args );
```

### wp-content/plugins/my-plugin/plugins/hello-world/hello-world.php

[](#wp-contentpluginsmy-pluginpluginshello-worldhello-worldphp)

Sub-Plugins work just like regular WordPress plugins, with one exception: I have made the deliberate change to include the (strtoupper'd) plugin prefix in the "Plugin-Name" attribute of the Plugin header.

This makes sub-plugins incompatible with WordPress (in case a user manually uploads it to the wrong folder) and also makes individual instances of the sub-plugin feature incompatible with each other to avoid confusion

```
    /**
     * BIONT-Plugin Name:    Hello World
     * Description:          A cool sub-plugin!
     * Version:              1.0
     * Author:               Biont
     * Licence:              GPLv3
     * Text Domain:          my-textdomain
     * Domain Path:          /languages
     */

     add_action('init', function(){
         echo 'Hello World!';
     });
```

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

3789d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/16e124446e13d0c8773106688a571f7afc645474750a5d8e7489e568f67d2822?d=identicon)[Biont](/maintainers/Biont)

---

Top Contributors

[![Biont](https://avatars.githubusercontent.com/u/4208996?v=4)](https://github.com/Biont "Biont (47 commits)")

---

Tags

pluginwordpresslibrarymodulemodularsub-plugin

### Embed Badge

![Health badge](/badges/biont-wordpress-subplugins/health.svg)

```
[![Health](https://phpackages.com/badges/biont-wordpress-subplugins/health.svg)](https://phpackages.com/packages/biont-wordpress-subplugins)
```

PHPackages © 2026

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