PluginProbe
Tamara Checkout / trunk
Tamara Checkout vtrunk
1.9.9.23 1.9.9.22 1.9.9.20 trunk 1.0.13 1.7.4 1.9.3 1.9.4 1.9.5 1.9.6 1.9.7 1.9.8 1.9.9 1.9.9.1 1.9.9.11 1.9.9.12 1.9.9.13 1.9.9.14 1.9.9.15 1.9.9.16 1.9.9.17 1.9.9.2 1.9.9.3 1.9.9.4 1.9.9.5 All 29 releases
tamara-checkout / tamara-checkout.php

tamara-checkout.php in Tamara Checkout trunk, at tamara-checkout.php

39 lines 1.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Plugin Name: Tamara Checkout
4 * Plugin URI: https://tamara.co/
5 * Description: With Tamara Buy Now Pay Later, you can split your payments – totally interest-free. Accepts payments from Mada, Apple Pay, or Credit Cards.
6 * Author: dev@tamara.co
7 * Author URI: https://tamara.co/
8 * Version: 1.9.9.23
9 * License: GPLv2 or later
10 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
11 * Text Domain: tamara-checkout
12 */
13
14 use Tamara\Wp\Plugin\TamaraCheckout;
15
16 defined('TAMARA_CHECKOUT_VERSION') || define('TAMARA_CHECKOUT_VERSION', '1.9.9.23');
17
18 // Use autoload if it isn't loaded before
19 // phpcs:ignore PSR2.ControlStructures.ControlStructureSpacing.SpacingAfterOpenBrace
20 if ( ! class_exists(TamaraCheckout::class)) {
21 require __DIR__ . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';
22 }
23
24 $config = require(__DIR__ . DIRECTORY_SEPARATOR . 'config.php');
25 $config = array_merge($config, [
26 'pluginFilename' => __FILE__,
27 ]);
28
29 // We need to set up the main instance for the plugin.
30 // Use 'woocommerce_init' to execute after WC init.
31 add_action('woocommerce_init', function () use ($config) {
32 TamaraCheckout::initInstanceWithConfig($config);
33
34 register_activation_hook(__FILE__, [TamaraCheckout::getInstance(), 'activatePlugin']);
35 register_deactivation_hook(__FILE__, [TamaraCheckout::getInstance(), 'deactivatePlugin']);
36
37 TamaraCheckout::getInstance()->initPlugin();
38 });
39