An example of a WordPress Custom Post Type designed for easy inclusion in a Roots/Bedrock project.
An example WordPress custom post type as a plugin using the fantastic PostTypes.
Designed for easy-inclusion with Roots Bedrock, but easily used in any WordPress project.
composer.json
to change the name of the plugin and the PSR-4 autoload namespaceplugin.php
, and the namespace in app/init.php
EXAMPLECPT_PLUGIN_DIR
and EXAMPLECPT_PLUGIN_URL
composer update
to regenerate the autoload filesapp/types/example.php
to fit your needsAdd the plugin to your WordPress plugins
or mu-plugins
directory, or include it as a Composer dependency in your Bedrock project.