定制 asrafuldev/wp-plugin-update-checker 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

asrafuldev/wp-plugin-update-checker

最新稳定版本:2.0.0

Composer 安装命令:

composer require asrafuldev/wp-plugin-update-checker

包简介

Lightweight WordPress plugin update checker for integrating with license servers. No external dependencies.

README 文档

README

Version Stability License PHP

Complete License Management & Update System for WordPress Plugins

A comprehensive solution for WordPress plugin licensing, updates, and support - integrated in just one line of code.

✨ Features

  • 🚀 One-Line Integration - Complete setup in single line
  • 🔒 License Management - Full activation/deactivation UI
  • 🔄 Automatic Updates - WordPress native update integration
  • 🎫 Support System - Built-in support ticket form
  • Hourly Validation - Automatic remote license checking
  • 💰 Free & Paid Support - Works for both business models
  • 🎨 Beautiful UI - WordPress-native admin interface
  • 📊 Usage Tracking - Track activations and updates

🚀 Quick Start

Installation

composer require asrafuldev/wp-plugin-update-checker

ONE-LINE Integration

<?php
// Load Composer autoloader
require_once __DIR__ . '/vendor/autoload.php';

// ONE LINE - Complete license system! 🎉
$license = new \WHB\UpdateChecker\LicenseClient([
    'slug' => 'my-plugin',
    'plugin_name' => 'My Awesome Plugin',
    'plugin_file' => __FILE__,
    'license_server_url' => 'https://license-server.com',
    'requires_license' => true, // true = paid, false = free
]);

// Optional: Check license before enabling features
if ($license->isLicenseValid()) {
    // Initialize premium features
}

That's it! You now have:

  • ✅ Complete license management page
  • ✅ Support ticket system
  • ✅ Automatic update checking
  • ✅ Hourly license validation
  • ✅ WordPress native update UI

📖 Complete Documentation

See ONE_LINE_INTEGRATION_GUIDE.md for full documentation.

🎯 Quick Examples

Free Plugin

$license = new \WHB\UpdateChecker\LicenseClient([
    'slug' => 'free-plugin',
    'plugin_name' => 'Free Plugin',
    'plugin_file' => __FILE__,
    'license_server_url' => 'https://server.com',
    'requires_license' => false, // FREE
]);

Paid Plugin

$license = new \WHB\UpdateChecker\LicenseClient([
    'slug' => 'paid-plugin',
    'plugin_name' => 'Premium Plugin',
    'plugin_file' => __FILE__,
    'license_server_url' => 'https://server.com',
    'requires_license' => true, // PAID
]);

🔌 Laravel API Required

Your license server needs these endpoints:

  • POST /api/v1/licenses/activate - Activate license
  • POST /api/v1/licenses/deactivate - Deactivate license
  • GET /api/v1/licenses/{key}/status - Check status
  • POST /api/v1/updates/check - Check for updates
  • POST /api/v1/support/tickets - Submit support ticket (optional)

📦 What You Get

Admin UI

  • License Tab - Activation/status
  • Support Tab - Submit tickets
  • About Tab - System information

Automation

  • Hourly license validation
  • Automatic update checks
  • WordPress native updates
  • Local database caching

Developer-Friendly

  • One-line integration
  • Feature gating support
  • Free/paid plugin modes
  • Extensible architecture

🎨 Configuration

$license = new \WHB\UpdateChecker\LicenseClient([
    // Required
    'slug' => 'my-plugin',
    'plugin_name' => 'My Plugin',
    'plugin_file' => __FILE__,
    'license_server_url' => 'https://server.com',
    
    // Optional
    'requires_license' => true,        // true = paid, false = free
    'update_check_period' => 12,       // Hours between update checks
    'license_check_period' => 1,       // Hours between license checks
    'parent_menu' => 'my-menu',        // Parent menu slug
    'support_enabled' => true,         // Enable support form
]);

🚀 Changelog

Version 2.0.0 (Current)

  • LicenseClient - One-line integration
  • ✅ Complete admin UI with tabs
  • ✅ Support ticket system
  • ✅ Free/paid plugin support
  • ✅ Hourly remote validation
  • ✅ Beautiful WordPress interface

Version 1.1.0

  • Added PluginUpdateChecker
  • Added hourly validation
  • Added local DB caching

📄 License

MIT License

🤝 Author

Asraful Islam

🎉 Complete license management in just one line of code!

统计信息

  • 总下载量: 3
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2025-12-13