<script charset="UTF-8" src="https://ssl.ditonlinebetalingssystem.dk/integration/ewindow/paymentwindow.js" type="text/javascript"></script>
<div id="epay-payment"></div>
<script type="text/javascript">
    paymentwindow = new PaymentWindow({
        'merchantnumber': '<?php echo $this->epay_merchantnumber; ?>',
        'currency': '<?php echo $this->currency; ?>',
        'amount': '<?php echo $this->amount; ?>',
        'orderid': '<?php echo $this->orderid; ?>',
        'language': '<?php echo $this->language; ?>',
        'windowstate': '<?php echo $this->epay_windowstate; ?>',<?php if($this->epay_windowstate == '4'): ?>

        'paymentcollection': '1',<?php endif; ?>

        'instantcapture': '<?php echo $this->instantcapture; ?>',
        'callbackurl': '<?php echo $this->callbackurl; ?>',
        'accepturl': '<?php echo $this->accepturl; ?>',
        'cancelurl': '<?php echo $this->cancelurl; ?>',
        'hash': '<?php echo md5($this->epay_merchantnumber . $this->currency . $this->amount . $this->orderid . $this->language . $this->epay_windowstate . ($this->epay_windowstate == '4' ? '1' : '') . $this->instantcapture . $this->callbackurl . $this->accepturl . $this->cancelurl . $this->epay_secretkey); ?>'
    });
    paymentwindow.append('epay-payment');
    paymentwindow.open();
</script>