create wordpress plugin code example
Example 1: wp plugin create
<?php
/**
* Plugin Name: My Plugin
* Description: A plugin
* Version: 1.1.1.0
* Author: E.Bisco
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly the file
// code snippet below
Example 2: wordpress plugin development
wordpress plugin file
/**
* Plugin Name
*
* @package PluginPackage
* @author Your Name
* @copyright 2019 Your Name or Company Name
* @license GPL-2.0-or-later
*
* @wordpress-plugin
* Plugin Name: Plugin Name
* Plugin URI: https://example.com/plugin-name
* Description: Description of the plugin.
* Version: 1.0.0
* Requires at least: 5.2
* Requires PHP: 7.2
* Author: Your Name
* Author URI: https://example.com
* Text Domain: plugin-slug
* License: GPL v2 or later
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt
*/
Example 3: 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.
Example 4: development wordpress plugin
/////neha jaiswal/////
<?php
/**
* Plugin Name: nehawp
* Plugin URI: https://example.com/plugins/the-basics/
* Description: Handle the basics with this plugin.
* Version: 1.10.3
* Requires at least: 5.2
* Requires PHP: 7.2
* Author: neha ///////your name////
* Author URI: https://author.example.com/
* License: GPL v2 or later
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
* Text Domain: my-basics-plugin
* Domain Path: /languages
*/
?>