This repository has been archived by the owner on May 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
/
wp-seo.php
72 lines (60 loc) · 2.66 KB
/
wp-seo.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
<?php
/**
* Plugin Name: WP SEO
* Plugin URI: https://github.com/alleyinteractive/wp-seo
* Description: An SEO plugin that stays out of your way. Just the facts, Jack.
* Version: 1.0.0
* Author: Alley Interactive
* Author URI: https://www.alleyinteractive.com/
*
* @package WP_SEO
*/
/*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
define( 'WP_SEO_PATH', dirname( __FILE__ ) );
define( 'WP_SEO_URL', trailingslashit( plugins_url( '', __FILE__ ) ) );
// Behind-the-scenes functions.
require_once WP_SEO_PATH . '/php/internal-functions.php';
// Core filters for the page title and meta tags, and post and term metaboxes.
require_once WP_SEO_PATH . '/php/class-wp-seo.php';
// Settings page and option management.
require_once WP_SEO_PATH . '/php/class-wp-seo-settings.php';
// Extendable formatting-tag class.
require_once WP_SEO_PATH . '/php/class-wp-seo-formatting-tag.php';
// Included formatting tags.
require_once WP_SEO_PATH . '/php/default-formatting-tags.php';
// General functions.
require_once WP_SEO_PATH . '/php/general-functions.php';
// Formatting functions.
require_once WP_SEO_PATH . '/php/formatting-functions.php';
// The plugin's default filters.
require_once WP_SEO_PATH . '/php/default-filters.php';
/**
* Enqueues scripts and styles for administration pages.
*/
function wp_seo_admin_scripts() {
wp_enqueue_script( 'wp-seo-admin', WP_SEO_URL . 'js/wp-seo.js', array( 'jquery', 'underscore' ), '0.11.1', true );
wp_localize_script( 'wp-seo-admin', 'wp_seo_admin', array(
'repeatable_add_more_label' => __( 'Add another', 'wp-seo' ),
'repeatable_remove_label' => __( 'Remove group', 'wp-seo' ),
/**
* Filter the fields that support character counts.
*
* @param array $fields Fields that support character counters.
*/
'character_count_fields' => (array) apply_filters( 'wp_seo_character_count_fields', [ 'title', 'description' ] ),
) );
wp_enqueue_style( 'wp-seo-admin', WP_SEO_URL . 'css/wp-seo.css', array(), '1.0.0' );
}
add_action( 'admin_enqueue_scripts', 'wp_seo_admin_scripts' );