-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwoocommerce-gateway-iyzico.php
66 lines (59 loc) · 1.92 KB
/
woocommerce-gateway-iyzico.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
/**
* iyzipay WooCommerce
*
* @package iyzico WooCommerce
* @author iyzico
* @copyright 2024 iyzico
* @license LGPL-3.0-or-later
*
* @wordpress-plugin
* Plugin Name: iyzico WooCommerce
* Plugin URI: https://wordpress.org/plugins/iyzico-woocommerce
* Description: iyzico Payment Gateway for WooCommerce.
* Version: 3.5.8
* Requires at least: 6.6.2
* WC requires at least: 9.3.3
* Requires PHP: 7.4.33
* Author: iyzico
* Author URI: https://iyzico.com
* Text Domain: woocommerce-iyzico
* Domain Path: /i18n/languages/
* License: LGPL v3 or later
* License URI: http://www.gnu.org/licenses/lgpl-3.0.txt
* Update URI: https://wordpress.org/plugins/iyzico-woocommerce
* Requires Plugins: woocommerce
*
* Tested up to: 6.6.2
* WC tested up to: 9.3.3
*/
defined('ABSPATH') || exit;
/**
* Constants
*
* These constants are used to define the plugin version, base file, path, url and language path.
*/
const PLUGIN_VERSION = '3.5.8';
const PLUGIN_BASEFILE = __FILE__;
define('PLUGIN_PATH', untrailingslashit(plugin_dir_path(PLUGIN_BASEFILE)));
define('PLUGIN_URL', untrailingslashit(plugin_dir_url(PLUGIN_BASEFILE)));
define('PLUGIN_LANG_PATH', plugin_basename(dirname(PLUGIN_BASEFILE)) . '/i18n/languages/');
define('PLUGIN_ASSETS_DIR_URL', plugin_dir_url(__FILE__) . 'assets');
define('PLUGIN_DIR_PATH', plugin_dir_path(__FILE__));
define('PLUGIN_DIR_URL', plugin_dir_url(__FILE__));
/**
* Composer Autoload
* This is used to autoload the classes.
*/
if (file_exists(PLUGIN_PATH . '/vendor/autoload.php')) {
require_once PLUGIN_PATH . '/vendor/autoload.php';
}
/**
* Plugin Activation and Deactivation
*/
register_activation_hook(PLUGIN_BASEFILE, ['\Iyzico\IyzipayWoocommerce\Core\Plugin', 'activate']);
register_deactivation_hook(PLUGIN_BASEFILE, ['\Iyzico\IyzipayWoocommerce\Core\Plugin', 'deactivate']);
/**
* Initialize the plugin
*/
add_action('plugins_loaded', ['\Iyzico\IyzipayWoocommerce\Core\Plugin', 'init']);