Permalink
Fetching contributors…
Cannot retrieve contributors at this time
78 lines (77 sloc) 2.6 KB
<?php
/**
* Solvingmagento_OneStepCheckout payment methods template
*
* PHP version 5.3
*
* @category Solvingmagento
* @package Solvingmagento_OneStepCheckout
* @author Magento Core Team <core@magentocommerce.com>
* @author Oleg Ishenko <oleg.ishenko@solvingmagento.com>
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com), 2014 Oleg Ishenko
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @version GIT: <0.1.0>
* @link http://www.solvingmagento.com/
*
*/
?>
<?php
/**
* One step checkout payment methods
*
* @see Mage_Checkout_Block_Onepage_Payment_Methods
*/
?>
<dl class="sp-methods" id="checkout-payment-method-load">
<?php
$methods = $this->getMethods();
$oneMethod = count($methods) <= 1;
?>
<?php
foreach ($methods as $_method):
$_code = $_method->getCode();
?>
<dt>
<?php if(!$oneMethod): ?>
<input
id="p_method_<?php echo $_code ?>"
value="<?php echo $_code ?>"
type="radio"
name="payment[method]"
title="<?php echo $this->htmlEscape($_method->getTitle()) ?>"
onclick="payment.switchMethod('<?php echo $_code ?>')"
<?php if($this->getSelectedMethodCode()==$_code): ?> checked="checked"<?php endif; ?>
class="radio" />
<?php else: ?>
<span class="no-display">
<input
id="p_method_<?php echo $_code ?>"
value="<?php echo $_code ?>"
type="radio"
name="payment[method]"
checked="checked"
class="radio" />
</span>
<?php $oneMethod = $_code; ?>
<?php endif; ?>
<label for="p_method_<?php echo $_code ?>">
<?php echo $this->escapeHtml($this->getMethodTitle($_method)) . ' '
. $this->getMethodLabelAfterHtml($_method) ?>
</label>
</dt>
<?php if ($html = $this->getPaymentMethodFormHtml($_method)): ?>
<dd>
<?php echo $html; ?>
</dd>
<?php endif; ?>
<?php endforeach; ?>
</dl>
<?php echo $this->getChildChildHtml('additional'); ?>
<script type="text/javascript">
//<![CDATA[
<?php echo $this->getChildChildHtml('scripts'); ?>
<?php if (is_string($oneMethod)): ?>
var switchToPaymentMethod = '<?php echo $oneMethod ?>';
<?php endif; ?>
//]]>
</script>