| 1 |
<?php |
| 2 |
/** |
| 3 |
* @link http://www.felixwelberg.de/ |
| 4 |
* @since 1.0.0 |
| 5 |
* |
| 6 |
* @wordpress-plugin |
| 7 |
* Plugin Name: Extended Post Status |
| 8 |
* Description: Add new post status types. |
| 9 |
* Version: 1.1.1 |
| 10 |
* Requires at least: 5.0 |
| 11 |
* Requires PHP: 7.2 |
| 12 |
* Author: Felix Welberg |
| 13 |
* Author URI: http://www.felixwelberg.de/ |
| 14 |
* License: GPL-2.0+ |
| 15 |
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt |
| 16 |
* Text Domain: extended-post-status |
| 17 |
* Domain Path: /languages |
| 18 |
*/ |
| 19 |
// If this file is called directly, abort. |
| 20 |
if (!defined('WPINC')) { |
| 21 |
die; |
| 22 |
} |
| 23 |
|
| 24 |
/** |
| 25 |
* Currently plugin version. |
| 26 |
* Start at version 1.0.0 and use SemVer - https://semver.org |
| 27 |
* Rename this for your plugin and update it as you release new versions. |
| 28 |
*/ |
| 29 |
define('EXTENDED_POST_STATUS_VERSION', '1.1.1'); |
| 30 |
|
| 31 |
/** |
| 32 |
* The code that runs during plugin activation. |
| 33 |
* This action is documented in includes/class-extended-post-status-activator.php |
| 34 |
*/ |
| 35 |
function activate_extended_post_status() |
| 36 |
{ |
| 37 |
require_once plugin_dir_path(__FILE__) . 'includes/class-extended-post-status-activator.php'; |
| 38 |
Extended_Post_Status_Activator::activate(); |
| 39 |
} |
| 40 |
|
| 41 |
/** |
| 42 |
* The code that runs during plugin deactivation. |
| 43 |
* This action is documented in includes/class-extended-post-status-deactivator.php |
| 44 |
*/ |
| 45 |
function deactivate_extended_post_status() |
| 46 |
{ |
| 47 |
require_once plugin_dir_path(__FILE__) . 'includes/class-extended-post-status-deactivator.php'; |
| 48 |
Extended_Post_Status_Deactivator::deactivate(); |
| 49 |
} |
| 50 |
register_activation_hook(__FILE__, 'activate_extended_post_status'); |
| 51 |
register_deactivation_hook(__FILE__, 'deactivate_extended_post_status'); |
| 52 |
|
| 53 |
/** |
| 54 |
* The core plugin class that is used to define internationalization, |
| 55 |
* admin-specific hooks, and public-facing site hooks. |
| 56 |
*/ |
| 57 |
require plugin_dir_path(__FILE__) . 'includes/class-extended-post-status.php'; |
| 58 |
|
| 59 |
/** |
| 60 |
* Begins execution of the plugin. |
| 61 |
* |
| 62 |
* Since everything within the plugin is registered via hooks, |
| 63 |
* then kicking off the plugin from this point in the file does |
| 64 |
* not affect the page life cycle. |
| 65 |
* |
| 66 |
* @since 1.0.0 |
| 67 |
*/ |
| 68 |
function run_extended_post_status() |
| 69 |
{ |
| 70 |
$plugin = new Extended_Post_Status(); |
| 71 |
$plugin->run(); |
| 72 |
} |
| 73 |
run_extended_post_status(); |
| 74 |
|