Plugin Directory

Changeset 2531418


Ignore:
Timestamp:
05/13/2021 08:49:21 PM (5 years ago)
Author:
codents
Message:

Added compatibility with Wordpress 5.7.2

Location:
simple-googlebot-visit/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • simple-googlebot-visit/trunk/changelog.txt

    r2465678 r2531418  
    11== Changelog ==
     2
     3= 1.2.1 =
     4* Added compatibility with Wordpress 5.7.2.
    25
    36= 1.2.0 =
  • simple-googlebot-visit/trunk/readme.txt

    r2465679 r2531418  
    44Tags: seo, googlebot, google, indexation, pages, entries, woocommerce, products
    55Requires at least: 3.0.1
    6 Tested up to: 5.6
     6Tested up to: 5.7.2
    77Stable tag: trunk
    88Requires PHP: 5.5
     
    4343== Changelog ==
    4444
     45= 1.2.1 =
     46* Added compatibility with Wordpress 5.7.2.
     47
    4548= 1.2.0 =
    4649* Added support for custom post types.
  • simple-googlebot-visit/trunk/simple-googlebot-visit.php

    r2465678 r2531418  
    11<?php
    22
    3     /**
    4     * @wordpress-plugin
    5     * Plugin Name:       Simple Googlebot Visit
    6     * Description:       Plugin to view the last visit of googlebot to your pages and entries.
    7     * Version:           1.2.0
    8     * Author:            Codents
    9     * Author URI:        https://codents.net
    10     * License:           GPL-2.0+
    11     * License URI:       http://www.gnu.org/licenses/gpl-2.0.txt
    12     * Text Domain:       simple-googlebot-visit
    13     * Domain Path:       /languages
    14     */
     3/**
     4 * @wordpress-plugin
     5 * Plugin Name:       Simple Googlebot Visit
     6 * Description:       Plugin to view the last visit of googlebot to your pages and entries.
     7 * Version:           1.2.1
     8 * Author:            Codents
     9 * Author URI:        https://codents.net
     10 * License:           GPL-2.0+
     11 * License URI:       http://www.gnu.org/licenses/gpl-2.0.txt
     12 * Text Domain:       simple-googlebot-visit
     13 * Domain Path:       /languages
     14 */
    1515
    16     if (!defined('WPINC')) {
    17         die;
    18     }
     16if (!defined('WPINC')) {
     17    die;
     18}
    1919
    20     define('SGBV_NAME', 'Simple Googlebot Visit');
    21     define('SGBV_SLUG', 'simple-googlebot-visit');
    22     define('SGBV_VERSION', '1.2.0');
    23     define('SGBV_DB_TERM', 'sgbv');
    24     define('SGBV_GOOGLEBOT_AGENTS', array('googlebot'));
    25    
    26     function activate_simple_googlebot_visit() {
    27         require_once plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit-activator.php';
    28         $activator = new Simple_Googlebot_Visit_Activator(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM);
    29         $activator->activate();
    30     }
     20define('SGBV_NAME', 'Simple Googlebot Visit');
     21define('SGBV_SLUG', 'simple-googlebot-visit');
     22define('SGBV_VERSION', '1.2.1');
     23define('SGBV_DB_TERM', 'sgbv');
     24define('SGBV_GOOGLEBOT_AGENTS', array('googlebot'));
    3125
    32     function deactivate_simple_googlebot_visit() {
    33         require_once plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit-activator.php';
    34         $activator = new Simple_Googlebot_Visit_Activator(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM);
    35         $activator->deactivate();
    36     }
     26function activate_simple_googlebot_visit() {
     27    require_once plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit-activator.php';
     28    $activator = new Simple_Googlebot_Visit_Activator(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM);
     29    $activator->activate();
     30}
    3731
    38     register_activation_hook(__FILE__, 'activate_simple_googlebot_visit');
    39     register_deactivation_hook(__FILE__, 'deactivate_simple_googlebot_visit');
     32function deactivate_simple_googlebot_visit() {
     33    require_once plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit-activator.php';
     34    $activator = new Simple_Googlebot_Visit_Activator(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM);
     35    $activator->deactivate();
     36}
    4037
    41     require plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit.php';
     38register_activation_hook(__FILE__, 'activate_simple_googlebot_visit');
     39register_deactivation_hook(__FILE__, 'deactivate_simple_googlebot_visit');
    4240
    43     function run_simple_googlebot_visit() {
    44         $plugin = new Simple_Googlebot_Visit(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM, SGBV_GOOGLEBOT_AGENTS);
    45         $plugin->run();
    46     }
     41require plugin_dir_path(__FILE__) . 'includes/class-simple-googlebot-visit.php';
    4742
    48     run_simple_googlebot_visit();
     43function run_simple_googlebot_visit() {
     44    $plugin = new Simple_Googlebot_Visit(SGBV_NAME, SGBV_SLUG, SGBV_VERSION, SGBV_DB_TERM, SGBV_GOOGLEBOT_AGENTS);
     45    $plugin->run();
     46}
     47
     48run_simple_googlebot_visit();
Note: See TracChangeset for help on using the changeset viewer.