forked from szelpe/woocommerce-barion
/
index.php
36 lines (28 loc) · 1.05 KB
/
index.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
<?php
/*
Plugin Name: Barion Payment Gateway for WooCommerce
Plugin URI: http://github.com/szelpe/woocommerce-barion
Description: Adds the ability to WooCommerce to pay via Barion
Version: 2.3.1
Author: Peter Szel <szelpeter@szelpeter.hu>
Author URI: http://szelpeter.hu
License: GNU General Public License v3.0
License URI: http://www.gnu.org/licenses/gpl-3.0.html
Text Domain: pay-via-barion-for-woocommerce
Domain Path: /languages
*/
add_action('plugins_loaded', 'woocommerce_gateway_barion_init', 0);
function woocommerce_gateway_barion_init() {
if (!class_exists('WC_Payment_Gateway'))
return;
load_plugin_textdomain('pay-via-barion-for-woocommerce', false, plugin_basename(dirname(__FILE__)) . "/languages");
require_once('class-wc-gateway-barion.php');
/**
* Add the Gateway to WooCommerce
**/
function woocommerce_add_gateway_barion_gateway($methods) {
$methods[] = 'WC_Gateway_Barion';
return $methods;
}
add_filter('woocommerce_payment_gateways', 'woocommerce_add_gateway_barion_gateway' );
}