Hi,
One of the options we'd like to use on our site is the ability for a customer to pay for an item using Direct Debit. This is a payment method in the UK where a customer enters bank details and an automatic payment is made yearly or monthly or whatever time period is necessary.
Now, I know that HikaShop doesn't support a Direct Debit module but we can embed our Direct Debit form into a page using an iframe supplied to us by our Direct Debit provider.
I have edited the existing payment method 'Pay on delivery' and just renamed this to 'Direct Debit'.
I'd like to know if there's a snippet of code i can add to the end.php file that checks to see if the payment method 'Direct Debit' was selected and then displays the iframe at the end of checkout for the customer to enter their details.
If the payment method was selected as something different such as Paypal then the iframe doesn't display within the end.php file.
Currently I've just got the Direct Debit form displaying all of the time but this clearly isn't correct.
<?php
/**
* @package HikaShop for Joomla!
* @version 2.1.0
* @author hikashop.com
* @copyright (C) 2010-2012 HIKARI SOFTWARE. All rights reserved.
* @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
*/
defined('_JEXEC') or die('Restricted access');
?>
<?php
echo ('<iframe style="background:#fff; border:1px solid #000;" width="100%" height="100%" src="DIRECT DEBIT FORM ADDRESS"> </iframe>');
?>
<?php
if(empty($this->html)){
echo JText::_('THANK_YOU_FOR_PURCHASE');
}else{
echo $this->html;
}
$this->nextButton = false;