Download the PHP package amalranganath/a-demo-plugin without Composer
On this page you can find all versions of the php package amalranganath/a-demo-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download amalranganath/a-demo-plugin
More information about amalranganath/a-demo-plugin
Files in amalranganath/a-demo-plugin
Package a-demo-plugin
Short Description A Framework Demo Plugin
License MIT
Homepage https://github.com/amalranganath/a-demo-plugin
Informations about the package a-demo-plugin
A Framework - Demo Plugin
A is a Simple MVC Framework to develop Wordpress plugins easily. This is the demo plugin created using A Framework which is to give you a brief idea about how it works. Please give it a try and report if you find any issues.
DIRECTORY STRUCTURE
assets/ contains assets definition
components/ contains components (any helper class)
controllers/ contains Web controller classes
models/ contains model classes
vendor/ contains dependent 3rd-party packages
views/ contains view files for the Web application
REQUIREMENTS
The minimum requirement by this project template that your Web server supports PHP 5.4.0. Also you should have installed Wordpress latest (at least 4.9.7) version.
INSTALLATION
Install via Composer
If you do not have Composer, you may install it by following the instructions at getcomposer.org.
Go to the wp-contet/plugins/ folder of your Wordpress project and type the following command:
composer create-project --stability=dev amalranganath/a-demo-plugin
cd a-demo-plugin/
composer update
Now you should be able to see the "A Demo Plugin" in the plugins listing.
START DEVELOPMENT
Find the plugin-name.php
file in plugin root wp-contet/plugins/a-demo-plugin/
folder and change the plugin details inside the comment as you wish.
Do not change the framework include code. You may define anything to run when activating the plugin inside register_activation_hook
as usual.
All the other developments go under "MVC" design as you can see inside the controllers, models and views folders.
CONFIGURATION
All configurations are defined in the file config.php
. Read the following sample code to get an idea how to define the each attribute:
When creating templates for the admin (in views/admin/) menu pages and tabs, file name should be the slug.
DOCUMENTATION
Coming soon ...