<?php

require_once '../lib/merchant.php';
try {
    $options = array('amount' => '50.00', 'currency' => 'EUR', 'service' => 'Eurobank');
    $intergration = Merchant_Billing_Integration::payment_service_for('1000', '*****@*****.**', $options);
    $intergration->billing_address(array('country' => 'Greece'))->currency('EUR')->customer(array('first_name' => 'John', 'last_name' => 'Doe'));
    Merchant_Logger::print_ar($intergration);
} catch (Exception $exc) {
    echo $exc->getMessage();
}
示例#2
0
<?php

require_once '../../lib/merchant.php';
require_once '../login.php';
Merchant_Billing_Base::mode('test');
try {
    $gateway = new Merchant_Billing_PiraeusPaycenter(array('acquire_id' => acquire_id, 'merchant_id' => merchant_id, 'pos_id' => pos_id, 'user' => user, 'password' => e_password, 'channel_type' => channel_type));
    $cc = new Merchant_Billing_CreditCard(array("first_name" => "Test", "last_name" => "User", "number" => "4111111111111111", "month" => "01", "year" => "2011", "verification_value" => "123"));
    $options = array('order_id' => $gateway->generate_unique_id());
    $response = $gateway->purchase('1', $cc, $options);
    Merchant_Logger::print_ar($response);
    if ($response->success()) {
        echo 'Success Authorize<br />';
        echo $response->message() . "<br />";
    } else {
        echo $response->message();
    }
} catch (Exception $e) {
    echo $e->getMessage();
}
示例#3
0
<?php

require_once '../../lib/merchant.php';
require_once '../login.php';
Merchant_Billing_Base::mode('test');
try {
    $gateway = new Merchant_Billing_Eurobank(array('login' => EUROBANK_LOGIN, 'password' => EUROBANK_PASS));
    $cc = new Merchant_Billing_CreditCard(array("first_name" => "Test", "last_name" => "User", "number" => "41111111111111", "month" => "12", "year" => "2012", "verification_value" => "123"));
    Merchant_Logger::print_ar($gateway->authorize('1', $cc, array('customer_email' => '*****@*****.**')));
} catch (Exception $e) {
    echo $e->getMessage();
}