Files
cf7-spam-to-telegram/cf7-spam-to-telegram.php
T
Vladimir Bryzgalov b0fb5c8e3d release: 1.2.0
2026-04-21 23:50:23 +05:00

31 lines
951 B
PHP

<?php
/**
* Plugin Name: CF7 Spam → Telegram
* Description: Пересылает spam-заявки Contact Form 7 в Telegram-группу с эвристической оценкой.
* Version: 1.2.0
* Author: Vladimir Bryzgalov
* Requires PHP: 7.4
* Requires at least: 6.0
* License: GPLv2 or later
* Text Domain: cf7-spam-to-telegram
*/
declare(strict_types=1);
if (!defined('ABSPATH')) exit;
define('CF7STG_PLUGIN_FILE', __FILE__);
define('CF7STG_PLUGIN_DIR', plugin_dir_path(__FILE__));
define('CF7STG_PLUGIN_URL', plugin_dir_url(__FILE__));
define('CF7STG_VERSION', '1.2.0');
require_once CF7STG_PLUGIN_DIR . 'includes/class-plugin.php';
\Cf7stg\Plugin::register_autoloader();
register_activation_hook(__FILE__, ['\\Cf7stg\\Activator', 'activate']);
register_deactivation_hook(__FILE__, ['\\Cf7stg\\Activator', 'deactivate']);
add_action('plugins_loaded', static function (): void {
\Cf7stg\Plugin::instance()->boot();
});