PluginProbe
Login Security Captcha / trunk
Login Security Captcha vtrunk
1.9.4 1.9.3 1.9.2 1.9.1 1.9.0 1.8.9 trunk 1.8.4 1.8.5 1.8.6 1.8.7 1.8.8
login-security-recaptcha / login-security-recaptcha.php

login-security-recaptcha.php in Login Security Captcha trunk, at login-security-recaptcha.php

52 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Plugin Name: Login Security Captcha
4 * Plugin URI: https://scriptstown.com/wordpress-plugins/login-security-recaptcha/
5 * Description: Secure WordPress login, registration, and comment form with Google reCAPTCHA or Cloudflare Turnstile. Prevent Brute-force attacks and more.
6 * Version: 1.9.4
7 * Author: ScriptsTown
8 * Author URI: https://scriptstown.com/
9 * License: GPL v2 or later
10 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
11 * Text Domain: login-security-recaptcha
12 * Requires at least: 5.3
13 * Requires PHP: 7.0
14 */
15
16 defined( 'ABSPATH' ) || die();
17
18 define( 'STLSR_PLUGIN_VERSION', '1.9.4' );
19 define( 'STLSR_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
20 define( 'STLSR_PLUGIN_DIR_PATH', plugin_dir_path( __FILE__ ) );
21 define( 'STLSR_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
22
23 final class STLSR_Login_Security_Recaptcha {
24 private static $instance = null;
25
26 private function __construct() {
27 $this->initialize_hooks();
28 $this->setup_database();
29 }
30
31 public static function get_instance() {
32 if ( is_null( self::$instance ) ) {
33 self::$instance = new self();
34 }
35 return self::$instance;
36 }
37
38 private function initialize_hooks() {
39 if ( is_admin() ) {
40 require_once STLSR_PLUGIN_DIR_PATH . 'admin/admin.php';
41 }
42 require_once STLSR_PLUGIN_DIR_PATH . 'public/public.php';
43 }
44
45 private function setup_database() {
46 require_once STLSR_PLUGIN_DIR_PATH . 'admin/inc/class-stlsr-database.php';
47 register_activation_hook( __FILE__, array( 'STLSR_Database', 'activation' ) );
48 register_deactivation_hook( __FILE__, array( 'STLSR_Database', 'deactivation' ) );
49 }
50 }
51 STLSR_Login_Security_Recaptcha::get_instance();
52