PluginProbe
Bulk Delete / 6.0.1
Bulk Delete v6.0.1
6.12 trunk 0.2 0.3 0.4 0.6 0.7 0.8 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.2.1 2.2.2 3.0 3.1 All 64 releases
bulk-delete / bulk-delete.php

bulk-delete.php in Bulk Delete 6.0.1, at bulk-delete.php

79 lines 2.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Plugin Name: Bulk Delete
4 * Plugin Script: bulk-delete.php
5 * Plugin URI: https://bulkwp.com
6 * Description: Bulk delete users and posts from selected categories, tags, post types, custom taxonomies or by post status like drafts, scheduled posts, revisions etc.
7 * Version: 6.0.1
8 * License: GPLv2 or later
9 * License URI: http://www.gnu.org/licenses/gpl-2.0.html
10 * Author: Sudar
11 * Author URI: https://sudarmuthu.com/
12 * Text Domain: bulk-delete
13 * Domain Path: languages/
14 * === RELEASE NOTES ===
15 * Check readme file for full release notes.
16 */
17
18 /**
19 * Copyright 2009 Sudar Muthu (email : sudar@sudarmuthu.com)
20 * This program is free software; you can redistribute it and/or modify
21 * it under the terms of the GNU General Public License, version 2, as
22 * published by the Free Software Foundation.
23 *
24 * This program is distributed in the hope that it will be useful,
25 * but WITHOUT ANY WARRANTY; without even the implied warranty of
26 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27 * GNU General Public License for more details.
28 *
29 * You should have received a copy of the GNU General Public License
30 * along with this program; if not, write to the Free Software
31 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
32 */
33 defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
34
35 // Include the stub of the old `Bulk_Delete` class, so that old add-ons don't generate a fatal error.
36 require_once 'include/Deprecated/old-bulk-delete.php';
37
38 if ( version_compare( PHP_VERSION, '5.3.0', '<' ) ) {
39 /**
40 * Version 6.0.0 of the Bulk Delete plugin dropped support for PHP 5.2.
41 * If you are still struck with PHP 5.2 and can't update, then use v5.6.1 of the plugin.
42 * But note that some add-ons may not work.
43 *
44 * @see http://sudarmuthu.com/blog/why-i-am-dropping-support-for-php-5-2-in-my-wordpress-plugins/
45 * @since 6.0.0
46 */
47 function bulk_delete_compatibility_notice() {
48 ?>
49 <div class="error">
50 <p>
51 <?php
52 printf(
53 __( 'Bulk Delete requires at least PHP 5.3 to function properly. Please upgrade PHP or use <a href="%s">v5.6.1 of Bulk Delete</a>.', 'bulk-delete' ), // @codingStandardsIgnoreLine
54 'https://downloads.wordpress.org/plugin/bulk-delete.5.6.1.zip'
55 );
56 ?>
57 </p>
58 </div>
59 <?php
60 }
61 add_action( 'admin_notices', 'bulk_delete_compatibility_notice' );
62
63 /**
64 * Deactivate Bulk Delete.
65 *
66 * @since 6.0.0
67 */
68 function bulk_delete_deactivate() {
69 deactivate_plugins( plugin_basename( __FILE__ ) );
70 }
71 add_action( 'admin_init', 'bulk_delete_deactivate' );
72
73 return;
74 }
75
76 // PHP is at least 5.3, so we can safely include namespace code.
77 require_once 'load-bulk-delete.php';
78 bulk_delete_load( __FILE__ );
79