how to create plugin in wordpress code example
Example: create a plugin demo wordpress
Login to your WordPress multisite network admin.
Head to Plugins -> Add New.
Enter Easy Plugin Demo into the search field.
Click to install the plugin.
Network Activate the plugin.
Go to Settings -> Easy Plugin Demo to set your preferences.