author | ymh <ymh.work@gmail.com> |
Tue, 22 Oct 2019 16:11:46 +0200 | |
changeset 15 | 3d4e9c994f10 |
parent 9 | 177826044cd9 |
permissions | -rw-r--r-- |
0 | 1 |
<?php |
2 |
/** |
|
3 |
* @package Akismet |
|
4 |
*/ |
|
5 |
/* |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
6 |
Plugin Name: Akismet Anti-Spam |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
7 |
Plugin URI: https://akismet.com/ |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
8 |
Description: Used by millions, Akismet is quite possibly the best way in the world to <strong>protect your blog from spam</strong>. It keeps your site protected even while you sleep. To get started: activate the Akismet plugin and then go to your Akismet Settings page to set up your API key. |
9 | 9 |
Version: 4.1.2 |
0 | 10 |
Author: Automattic |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
11 |
Author URI: https://automattic.com/wordpress-plugins/ |
0 | 12 |
License: GPLv2 or later |
5 | 13 |
Text Domain: akismet |
0 | 14 |
*/ |
15 |
||
16 |
/* |
|
17 |
This program is free software; you can redistribute it and/or |
|
18 |
modify it under the terms of the GNU General Public License |
|
19 |
as published by the Free Software Foundation; either version 2 |
|
20 |
of the License, or (at your option) any later version. |
|
21 |
||
22 |
This program is distributed in the hope that it will be useful, |
|
23 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
24 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
25 |
GNU General Public License for more details. |
|
26 |
||
27 |
You should have received a copy of the GNU General Public License |
|
28 |
along with this program; if not, write to the Free Software |
|
29 |
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
30 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
31 |
Copyright 2005-2015 Automattic, Inc. |
0 | 32 |
*/ |
33 |
||
34 |
// Make sure we don't expose any info if called directly |
|
35 |
if ( !function_exists( 'add_action' ) ) { |
|
36 |
echo 'Hi there! I\'m just a plugin, not much I can do when called directly.'; |
|
37 |
exit; |
|
38 |
} |
|
39 |
||
9 | 40 |
define( 'AKISMET_VERSION', '4.1.2' ); |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
41 |
define( 'AKISMET__MINIMUM_WP_VERSION', '4.0' ); |
5 | 42 |
define( 'AKISMET__PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); |
43 |
define( 'AKISMET_DELETE_LIMIT', 100000 ); |
|
0 | 44 |
|
5 | 45 |
register_activation_hook( __FILE__, array( 'Akismet', 'plugin_activation' ) ); |
46 |
register_deactivation_hook( __FILE__, array( 'Akismet', 'plugin_deactivation' ) ); |
|
0 | 47 |
|
5 | 48 |
require_once( AKISMET__PLUGIN_DIR . 'class.akismet.php' ); |
49 |
require_once( AKISMET__PLUGIN_DIR . 'class.akismet-widget.php' ); |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
50 |
require_once( AKISMET__PLUGIN_DIR . 'class.akismet-rest-api.php' ); |
0 | 51 |
|
5 | 52 |
add_action( 'init', array( 'Akismet', 'init' ) ); |
0 | 53 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
54 |
add_action( 'rest_api_init', array( 'Akismet_REST_API', 'init' ) ); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
55 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
56 |
if ( is_admin() || ( defined( 'WP_CLI' ) && WP_CLI ) ) { |
5 | 57 |
require_once( AKISMET__PLUGIN_DIR . 'class.akismet-admin.php' ); |
58 |
add_action( 'init', array( 'Akismet_Admin', 'init' ) ); |
|
0 | 59 |
} |
60 |
||
5 | 61 |
//add wrapper class around deprecated akismet functions that are referenced elsewhere |
62 |
require_once( AKISMET__PLUGIN_DIR . 'wrapper.php' ); |
|
0 | 63 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
64 |
if ( defined( 'WP_CLI' ) && WP_CLI ) { |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
65 |
require_once( AKISMET__PLUGIN_DIR . 'class.akismet-cli.php' ); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
66 |
} |