WPU Base Plugin
A Framework to create your WordPress plugin.
by Darklg · github.com/wordpressutilities/wpubaseplugin · website
★ 4stars
0forks
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/wordpressutilities/wpubaseplugin/archive/refs/heads/main.zipDeclares an update source (https://github.com/WordPressUtilities/wpubaseplugin), so updates arrive through the plugin's own updater.
From the readme
Base Plugin
A Framework to create your WordPress plugin.
How to use only an utility class :
Get the utility class file (like WPUBaseCron.php)
Change the namespace to your plugin ID (to avoid conflicts).
Include it into your plugin, using the method described in the file's README.
How to start a new plugin with it :
Choose a plugin id and a plugin name.
Change the plugin name :
Into the plugin header (comment at the top).
Into the setoptions() function.
Change the id :
The plugin folder name.
The plugin main file name.
Into the setoptions() function.
Into uninstall.php
The lang .po & .mo files (wpubaseplugin-frFR.mo - myawesomeplugin-frFR.mo)
Change the PHP class name (use the id with camelcase if you are not inspired)
Into the class declaration ( class wpuBasePlugin extends wpuBasePluginUtilities - class myAwesomePlugin extends wpuBasePluginUtilities )
Into the class launch ( $wpuBasePlugin = new wpuBasePlugin(); - $myAwesomePlugin = new myAwesomePlugin(); )
Into the activation & deactivation calls.
Into uninstall.php
What can you do with it ?
You can create admin pages.
You can create paginated tables in admin pages.
You can create a hook tri