<?php
$xml = "<?xml version='1.0' encoding='utf-8' ?>";
$xml .= '
<order>
    <userAccountId>260011</userAccountId>
    <currency>EUR</currency>
    <label>Account Charge</label>
    <ageGroup>ALL</ageGroup>
    <categoryId>654</categoryId>
    <urlAcquital><![CDATA[http://hostedbyinbound.be/fineartinvest/root/incs/getHP2.php?uid=8292738&utid=1440268840]]></urlAcquital>
    <urlOk><![CDATA[http://hostedbyinbound.be/fineartinvest/finance]]></urlOk>
    <urlKo><![CDATA[http://hostedbyinbound.be/fineartinvest/finance]]></urlKo>
    <urlCancel><![CDATA[http://hostedbyinbound.be/fineartinvest/finance]]></urlCancel>
    <urlInstall><![CDATA[http://hostedbyinbound.be/fineartinvest/finance]]></urlInstall>
    <urlLogo><![CDATA[http://fine-art-invest.com/members/root/img/FAIlogoSmall.jpg]]></urlLogo>
    <paymentmethod>0</paymentmethod>
    <captureday>0</captureday>
    <!-- optional -->
    <locale>en_EN</locale>
    <issuerAccountLogin>frent.be'. time() .'@gmail.com</issuerAccountLogin>
    <items>
        <item id="1">
            <name>Fine Art Invest</name>
            <infos>Account Charge</infos>
            <amount>1000</amount>
            <categoryId>654</categoryId>
            <quantity>1</quantity> yyy
            <reference>REF123</reference>
        </item>
    </items>
</order>';
 
$data = trim($xml);
 
// your website Hipay key
$signKey = '41a31105668bc6ab30f611878209cdf8';
$encodedData = base64_encode($data);
$md5Sign = md5($encodedData.$signKey);
 
echo "<form target='_blank' action='https://test-payment.hipay.com/index/form/' method='post'>";
echo "<input type='hidden' name='mode' value='MODE_B' />";
echo "<input type='hidden' name='website_id' value='141418' />";
echo "<input type='hidden' name='sign' value='".$md5Sign."' />";
echo "<input type='hidden' name='data' value='".$encodedData."' />";
echo "<input type='image' name='send' src='https://test-www.hipaywallet.com/images/i18n/en/bt_payment_7.png' />";
echo "</form>";