integrate with Ideal pay method

Dakey

No avatar

2007-07-30 21:57

Sorry for my late reply,

It depends which bank u use.. postbank configuration is a little different than ABNAMRO.
The formfields are almost the same, you have to see which configuration you're bank is using/accepting, and use only that in the formfields.

Does anyone has some experience with other banks configuration?

Leonidaz

No avatar

2007-08-13 13:00

@nicarcola My guess is You use HTML email plugin, I encountered the same problem. There is a simle fix but I have to search what to modify...

Jerry678

No avatar

2007-08-22 13:38

Hi I implemented the iDeal code local on a xammp server but I got this error message while paying:
Notice: Use of undefined constant sCourier - assumed 'sCourier' in F:\xampplite\htdocs\winkelideal\actions_client\orders.php on line 65
on line 65 it says:if($aData[sCourier] == "iDeal" ){
How can I solve this?

Thanks for your advise, Jeroen

Leonidaz

No avatar

2007-08-24 09:12

@nicarcola:
In plugins/htmlmailorderdetails/actions_client.php
add an extra line for ideal, the file should look like this:

<?php
/*
* actions_client.php for htmlMailOrderDetails plugin
* Wizzud: 31/01/06
*/
if(extendedTplParser() && $oMail->isSetIntercept() === false)
$oMail->setInterceptID( $tpl->newIntercept('messages.tpl', 'messages.tpl', 'ORDER_SAVED', 'ORDER_SAVED', 'sendHtmlMailDetails', '') );
$oMail->setInterceptID( $tpl->newIntercept('messages.tpl', 'messages.tpl', 'ORDER_IDEAL', 'ORDER_IDEAL', 'sendHtmlMailDetails', '') );
?>

Leonidaz

No avatar

2007-08-24 09:36

@Jerry678: I tried to find the reason for your error but cannot find it on short notice. It also depends on what version of QC you are implementing! I really haven't got much time to spend on fixing errors, sorry. Good luck

M.Braam

No avatar

2007-09-08 21:05

Is er een handleiding ergens of ... hoe je dit kan inbouwen in dit systeem?
Zelf wil ik dit ook inbouwen maar ik weet totaal niet waar ik moet zijn en wat ik moet aanpassen.

Of kan ik met iemand contact kan opnemen die mij zou kunnen helpen hiermee?

Alvast enorm bedankt!

Met vriendelijke groet, Michael Braam

Leonidaz

No avatar

2007-09-28 13:13

@ M.Braam

Ik kan de installatie voor mijn rekening nemen maar daar zijn wel ksoten aan verbonden.
Kijk anders op www.talpadesign.nl voor meer info en contactinformatie

Dakey

No avatar

2007-09-28 20:41

Thanks for the solution Leonidaz, I had the same problem, with you're code it is working again for me :-)

M.Braam

No avatar

2007-10-10 20:44

@Leonidaz ,

Bedankt voor het aanbod maar het is nogal aan de prijzige kant en ik heb al een afspraak gemaakt met de klant over de kosten en helaas kan ik dat bedrag niet door berekenen.

En ik zie hier dat het meerdere is gelukt dus wie zou mij kunnen helpen hiermee?

Alvast bedankt ;)

Dakey

No avatar

2007-10-11 21:45

Damn,

right now I have some problems with ABN-AMRO...
It seems that this bank has changed their way of providing the amount data.

If the price is like 130.00, the formfileld will deliver 130.00 to the bank.
Now it should be amount * 100

So 130.00 should be 13000 in the formfield which has to be send to the bank.

Anybody can help me with this, i'm a little bit lost right now..

merci

No avatar

2007-10-12 09:47

Dakey - open file actions_client/orders.php and above this line:

$content .= $tpl->tbHtml'messages.tpl''ORDER_IDEAL' );

insert:

$aData['fSummary'] = ereg_replace'.'''$aData['fSummary'] );

Dakey

No avatar

2007-10-12 12:54

Thanks for you're quick response merci.
I will try this tonight when I'm home, I will let you know if it works..

Dakey

No avatar

2007-10-12 21:02

Hi merci,

I've tried you're possible solution, but unfortunately it won't work... :-(

The code in actions_client/orders.php which was working fine until a few days ago:

<FORM METHOD="post" ACTION="https://internetkassa.abnamro.nl/ncol/prod/orderstandard.asp";
id=form1 name=form1>
<INPUT type="hidden" NAME="PSPID" value="PSPID">
<INPUT type="hidden" NAME="subID" value="0">
<INPUT type="hidden" NAME="amount" VALUE="109.00" >
<INPUT type="hidden" NAME="orderID" VALUE="887">
<INPUT type="hidden" NAME="language" VALUE="NL_NL">
<INPUT type="hidden" NAME="currency" VALUE="EUR">
<INPUT type="hidden" NAME="description" VALUE="iDEAL Aankoop">
<INPUT type="hidden" NAME="itemNumber1" VALUE="112">
<INPUT type="hidden" NAME="itemDescription1" VALUE="Order ID 887 ">
<INPUT type="hidden" NAME="itemQuantity1" VALUE="1">
<INPUT type="hidden" NAME="itemPrice1" VALUE="109.00">
<INPUT type="hidden" NAME="paymentType" VALUE="iDEAL">
<INPUT type="hidden" NAME="validUntil" VALUE=" 2007-01-01T12:00:00:0000Z">

<INPUT TYPE="image" SRC="http://someserver/ideal.gif"; id=submit2 name=submit2 BORDER="0" ALT="iDEAl">
</FORM>

Now it's not working anymore because the formfield "amount" and "itemPrice1" are showing 109.00, and the ABN bank now only accepts amount without the . and price * 100

The amount and itemprice field has to be filled like this:

<INPUT type="hidden" NAME="amount" VALUE="10900" >
<INPUT type="hidden" NAME="itemPrice1" VALUE="10900">

I've tried this in a static html page, just for testing if it really works, and it worked, so now is the question how it will work in a dynamical environment :-(

merci

No avatar

2007-10-15 09:38

Dakey - which value do you have put here:<INPUT type="hidden" NAME="amount" VALUE="109.00" > ?

Dakey

No avatar

2007-10-15 21:45

The price of a product is 109.00 euro (filled in the admin section of QC)
The value is dynamicle build (see also in the example in the first post in this topic):

in templates/messages.tpl:
<INPUT type="hidden" NAME="amount" VALUE="$aData[fSummary]" >
where in the html output $aData[fSummary] = in my case 109.00

The strange part is (i guess), when you look at the code in actions_client/orders.php, a line is saying:

$aData['fSummary'] = ($aData['fCourierPrice'] + $aList['fSummary'])*100;

The "*100" part, isn't that the thing that I want? Because from the beginning I used this code, but the amount has never been other that 109.00 ...

merci

No avatar

2007-10-16 08:37

Dakey - sorry, there was a mistake in code I send you earlier, here is a good code, try again:
open file actions_client/orders.php and above this line:

$content .= $tpl->tbHtml'messages.tpl''ORDER_IDEAL' ); 


insert:

$aData['fSummary'] = ereg_replace'\.'''$aData['fSummary'] );

Dakey

No avatar

2007-10-17 00:10

I've tried but still same amount shows up:

<INPUT type="hidden" NAME="amount" VALUE="109.00" >

:-(

merci

No avatar

2007-10-17 09:09

Dakey - I don't know, why it doesn't work for you...I have tested it, and it works good. Are you sure, that you put it in good place? Or maybe you have modified your code somehow that this solution doesn't work for you...maybe ask some php programist to do it for you.

Dakey

No avatar

2007-10-17 18:31

yup, i put it in the good place.
Maybe is it possible that it won't work because i use the 1.4 version of qc?

Leonidaz

No avatar

2007-10-20 22:51

@ Dakey - I had the same problem with a rabobank config. Seems to me like a courier plugin messes things up. To avoid the problem I used the ABN way of converting the item price. See below for the new code

<!-- BEGIN ORDER_IDEAL -->
<div id="message">
<div id="ok">

$lang[Order_ideal]<br />

<script type="text/javascript">
var Amount = $aData[fSummary];
var AM;
if (isNaN(Amount))
{
alert("Amount not a number: " + Amount + " !");
AM = ""
}
else
{
AM = Math.round(parseFloat(Amount)*100);
}
</script>

<FORM METHOD="post" ACTION="https://ideal.rabobank.nl/ideal/mpiPayInitRabo.do";
id=form name=form> <!--adjust URL to required enviroment-->
<INPUT type="hidden" NAME="merchantID" value="XXXXXXX"><!--adjust merchant number-->
<INPUT type="hidden" NAME="subID" value="0">
<script type="text/javascript">
document.write("<input type=\"hidden\" NAME=\"amount\" value=\"" + AM + "\" />");
document.write("<input type=\"hidden\" NAME=\"itemPrice1\" value=\"" + AM + "\" />");
</script>
<INPUT type="hidden" NAME="purchaseID" VALUE="$iOrder">
<INPUT type="hidden" NAME="language" VALUE="nl">
<INPUT type="hidden" NAME="currency" VALUE="EUR">
<INPUT type="hidden" NAME="description" VALUE="XXXXXXXX">
<INPUT type="hidden" NAME="itemNumber1" VALUE="XXXXXXXX"><!--adjust product number-->
<INPUT type="hidden" NAME="itemDescription1" VALUE="Order ID $iOrder ">
<INPUT type="hidden" NAME="itemQuantity1" VALUE="1">
<INPUT type="hidden" NAME="paymentType" VALUE="ideal">
<INPUT type="hidden" NAME="validUntil" VALUE="2007-01-01T12:00:00:0000Z">
<INPUT type="hidden" NAME="urlCancel" VALUE="http://www.XXXXX.nl"><!--adjust URL-->
<INPUT type="hidden" NAME="urlSuccess" VALUE="http://www.XXXXX.nl"><!--adjust URL-->
<INPUT type="hidden" NAME="urlError" VALUE="http://www.XXXXX.nl"><!--adjust URL-->
<INPUT TYPE="image" SRC="http://217.194.103.68/uploads/documents/57.gif"; id=submit2 name=submit2 BORDER="0" ALT="iDEAL" onClick="writeText(this.form)"><!--Please use your own iDEAl logo-->
</form>


</form>
<a href="javascript:windowNew( '?p=ordersWindowPrint&amp;iOrder=$iOrder' );">&raquo; $lang[Order_print]</a><br />
</div>
</div>
<!-- END ORDER_IDEAL -->

Back to top
about us | contact