Plugin Directory

Changeset 3304399


Ignore:
Timestamp:
06/01/2025 05:41:51 PM (9 months ago)
Author:
wp24dotorg
Message:

Version 1.11.1

Location:
wp24-domain-check/trunk
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • wp24-domain-check/trunk/assets/inc/class-whoisservers.php

    r3237418 r3304399  
    11211121        'reise' => array('host' => 'whois.nic.reise', 'free' => 'not found'),
    11221122        'reisen' => array('host' => 'whois.donuts.co', 'free' => 'domain not found.'),
     1123        'ren' => array('host' => 'whois.nic.ren', 'free' => 'object does not exist'),
    11231124        'rentals' => array('host' => 'whois.donuts.co', 'free' => 'domain not found.'),
    11241125        'repair' => array('host' => 'whois.donuts.co', 'free' => 'domain not found'),
  • wp24-domain-check/trunk/includes/class-wp24-options.php

    r2878635 r3304399  
    154154
    155155        // backward compatibility with v1.8.1
    156         if ( ! isset( $options['woocommerce']['addToCartBehaviour'] ) && $options['woocommerce']['redirectToCart'] )
     156        if ( isset( $options['woocommerce'] ) && ! isset( $options['woocommerce']['addToCartBehaviour'] ) && $options['woocommerce']['redirectToCart'] )
    157157            $options['woocommerce']['addToCartBehaviour'] = 0;
    158158
  • wp24-domain-check/trunk/includes/class-wp24-settings.php

    r3237418 r3304399  
    9999     */
    100100    public function init() {
    101         add_action( 'plugins_loaded', array( $this, 'update_database' ) );
    102101        add_action( 'upgrader_process_complete', array( $this, 'update_plugin' ), 10, 2 );
    103102        add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) );
     
    105104        add_action( 'admin_init', array( $this, 'init_settings' ) );
    106105        add_action( 'admin_menu', array( $this, 'init_menu' ) );
    107     }
    108 
    109     /**
    110      * Check database version and update if necessary.
    111      *
    112      * @return void
    113      */
    114     public function update_database() {
    115         if ( ! isset( $this->options['database_version'] ) ||
    116             version_compare( $this->options['database_version'], WP24_DOMAIN_CHECK_DATABASE_VERSION ) == -1 ) {
    117             global $wpdb;
    118 
    119             $charset_collate = $wpdb->get_charset_collate();
    120            
    121             $table_name = $wpdb->prefix . 'wp24_whois_queries';
    122             $sql[] = "CREATE TABLE $table_name (
    123                 id bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT,
    124                 limit_group varchar(25) NOT NULL,
    125                 query_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL,
    126                 query_count smallint(5) DEFAULT 1 NOT NULL,
    127                 PRIMARY KEY  (id)
    128             ) $charset_collate;";
    129 
    130             $table_name = $wpdb->prefix . 'wp24_tld_prices_links';
    131             $sql[] = "CREATE TABLE $table_name (
    132                 tld varchar(25) NOT NULL,
    133                 price varchar(25),
    134                 link text,
    135                 price_transfer varchar(25),
    136                 link_transfer text,
    137                 PRIMARY KEY  (tld)
    138             ) $charset_collate;";
    139 
    140             $table_name = $wpdb->prefix . 'wp24_tld_woocommerce';
    141             $sql[] = "CREATE TABLE $table_name (
    142                 tld varchar(25) NOT NULL,
    143                 product_id_purchase bigint(20),
    144                 product_id_transfer bigint(20),
    145                 PRIMARY KEY  (tld)
    146             ) $charset_collate;";
    147 
    148             $table_name = $wpdb->prefix . 'wp24_whois_servers';
    149             $sql[] = "CREATE TABLE $table_name (
    150                 tld varchar(25) NOT NULL,
    151                 host varchar(100),
    152                 status_free varchar(200),
    153                 PRIMARY KEY  (tld)
    154             ) $charset_collate;";
    155 
    156             require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );
    157             dbDelta( $sql );
    158 
    159             $this->options['database_version'] = WP24_DOMAIN_CHECK_DATABASE_VERSION;
    160             update_option( 'wp24_domaincheck', $this->options );
    161         }
    162106    }
    163107
     
    22422186    }
    22432187
    2244     /**
    2245      * Uninstall plugin.
    2246      *
    2247      * @return void
    2248      */
    2249     public static function uninstall() {
    2250         global $wpdb;
    2251 
    2252         // drop tables
    2253         $table_name = $wpdb->prefix . 'wp24_whois_queries';
    2254         $sql = "DROP TABLE IF EXISTS $table_name";
    2255         $wpdb->query( $sql );
    2256         $table_name = $wpdb->prefix . 'wp24_tld_prices_links';
    2257         $sql = "DROP TABLE IF EXISTS $table_name";
    2258         $wpdb->query( $sql );
    2259         $table_name = $wpdb->prefix . 'wp24_tld_woocommerce';
    2260         $sql = "DROP TABLE IF EXISTS $table_name";
    2261         $wpdb->query( $sql );
    2262         $table_name = $wpdb->prefix . 'wp24_whois_servers';
    2263         $sql = "DROP TABLE IF EXISTS $table_name";
    2264         $wpdb->query( $sql );
    2265        
    2266         // delete all settings
    2267         delete_option( 'wp24_domaincheck' );
    2268     }
    2269 
    22702188}
  • wp24-domain-check/trunk/readme.txt

    r3237418 r3304399  
    22Contributors: wp24dotorg
    33Donate link: https://wp24.org/donate
    4 Tags: domain check, domain checker, domain, whois
     4Tags: domaincheck, domain check, domain checker, domain, whois
    55Requires at least: 5.0
    6 Tested up to: 6.7
    7 Stable tag: 1.11.0
     6Tested up to: 6.8
     7Stable tag: 1.11.1
    88Requires PHP: 7.0.0
    99License: GPLv2
     
    5353== Changelog ==
    5454
     55= 1.11.1 =
     56* Minor bug fixes
     57
    5558= 1.11.0 =
    5659* WooCommerce variable and grouped products
  • wp24-domain-check/trunk/wp24-domain-check.php

    r3237418 r3304399  
    44 * Plugin URI: https://wp24.org/plugins/domain-check
    55 * Description: Check (whois) domain names for availability. Easy integration via shortcode or widget.
    6  * Version: 1.11.0
     6 * Version: 1.11.1
    77 * Author: WP24
    88 * Author URI: https://wp24.org
     
    1818
    1919if ( ! defined( 'WP24_DOMAIN_CHECK_VERSION' ) )
    20     define( 'WP24_DOMAIN_CHECK_VERSION', '1.11.0' );
     20    define( 'WP24_DOMAIN_CHECK_VERSION', '1.11.1' );
    2121
    2222if ( ! defined( 'WP24_DOMAIN_CHECK_DATABASE_VERSION' ) )
     
    3030    require_once( plugin_dir_path( __FILE__ ) . '/includes/class-wp24-widget.php' );
    3131
     32if ( is_admin() ) {
     33    if ( ! class_exists( 'WP24_Domain_Check_Setup' ) )
     34        require_once( plugin_dir_path( __FILE__ ) . '/includes/class-wp24-setup.php' );
     35
     36    add_action( 'plugins_loaded', function() {
     37        WP24_Domain_Check_Setup::update_database();
     38    } );
     39
     40    register_uninstall_hook( __FILE__, array( 'WP24_Domain_Check_Setup', 'uninstall' ) );
     41}
     42
    3243add_action( 'init',  function() {
    33     load_plugin_textdomain( 'wp24-domain-check', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
    34 
    3544    // create and init domain check
    3645    $wp24_domain_check = new WP24_Domain_Check();
     
    4655    }
    4756} );
    48 
    49 register_uninstall_hook( __FILE__, array( 'WP24_Domain_Check_Settings', 'uninstall' ) );
Note: See TracChangeset for help on using the changeset viewer.