HEX
Server: nginx
System: Linux f62c58717270 6.1.0-17-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.69-1 (2023-12-30) x86_64
User: www-data (1000)
PHP: 8.0.30
Disabled: NONE
Upload Files
File: /www/sites/timexsaleall.com/index/wp-content/plugins/ppcard/ppcard.php
<?php

/*
Plugin Name: PPCard payments gateways
Description: An WooCommerce payment toolkit that helps you sell anything .Beautifully
Author: ppcard.PG
Version: v1.2.0
*/

defined('ABSPATH') || exit;

define('PPCARD_GATEWAY_VERSION', 'v1');
define('PPCARD_PLUGIN_VERSION', 'v1.2.0');
define('PPCARD_PLUGIN_URL', untrailingslashit(plugins_url(basename(plugin_dir_path(__FILE__)), basename(__FILE__))));
define('PPCARD_PLUGIN_PATH', __DIR__ . '/');
define('PPCARD_PLUGIN_NAME', 'ppcard');

function ppcard_load_textdomain() // @codingStandardsIgnoreLine
{
    load_plugin_textdomain(
        PPCARD_PLUGIN_NAME,
        false,
        dirname(plugin_basename(__FILE__)) . '/languages'
    );
}
add_action('init', 'ppcard_load_textdomain', 1);

function ppcard_init()  // @codingStandardsIgnoreLine
{
    if (!class_exists('WooCommerce')) {
        add_action('admin_notices', function () {
            echo '<div class="error"><p><strong>' . __('ppcard requires WooCommerce to be installed and active.', PPCARD_PLUGIN_NAME) . '</strong></p></div>';
        });
        return;
    }

    require_once PPCARD_PLUGIN_PATH . 'includes/main.php';
    require_once PPCARD_PLUGIN_PATH . 'includes/gateways/gatewayTrait.php';
    foreach (glob(PPCARD_PLUGIN_PATH . 'includes/*/*.php') as $includeFile) {
        require_once $includeFile;
    }

    $ppcard = PPCard\Main::getInstance();
    $ppcard->init();
    add_action('wp_enqueue_scripts', [$ppcard, 'addPluginJs']);
}

add_action('init', 'ppcard_init');