Example #1
0
 function onTP_GetHTML($vars)
 {
     $plgPaymentGtpayHelper = new plgPaymentGtpayHelper();
     $vars->action_url = $plgPaymentGtpayHelper->buildGtpayUrl();
     $session = JFactory::getSession();
     $session->set('amount', $vars->amount);
     $session->set('email', $vars->paypal_email);
     //Take this receiver email address from plugin if component not provided it
     //if component does not provide cmd
     if (empty($vars->cmd)) {
         $vars->cmd = '_xclick';
     }
     $html = $this->buildLayout($vars);
     return $html;
 }
Example #2
0
<?php

/**
 *  @copyright  Copyright (c) 2009-2013 TechJoomla. All rights reserved.
 *  @license    GNU General Public License version 2, or later
 */
defined('_JEXEC') or die('Restricted access');
$plgPaymentGtpayHelper = new plgPaymentGtpayHelper();
$vars->currency_val = $plgPaymentGtpayHelper->currencyConvert();
$gtpay_tranx_id = rand();
$gtpay_cust_id = rand();
?>
<form name="gtpay_test" action="<?php 
echo $vars->action_url;
?>
" method="post">
<div class="row-fluid form-horizontal">
	<input id="gtpay_mert_id" type="hidden" name="gtpay_mert_id" value="<?php 
echo $this->params->get('gtpay_mert_id');
?>
">
	<input id="gtpay_tranx_id" type="hidden" name="gtpay_tranx_id" value="<?php 
echo $gtpay_tranx_id;
?>
" >
	<input id="gtpay_tranx_amt" type="hidden" name="gtpay_tranx_amt" value="<?php 
echo $vars->amount * 100;
?>
" >
	<input id="gtpay_tranx_curr" type="hidden" name="gtpay_tranx_curr" value="<?php 
echo $vars->currency_val;