Re: $order->info['total']
Sorry about the multiple threads but its pretty obvious that if I don't get any replies, I'm going to try another angle ! I would gladly remove/edit posts but this forum does not provide this possibility.
Payline is dead as my web host doesn't offer Soap support, which Payline needs. Paypal is installed and works but doesn't offer the possibility of debitting the balance of an order when the goods are dispatched - I would have to ask the customers to pay by email which means that if they don't look at their emails then I won't get paid. Atos is the French bank module which allows me to initiate payment of the balance without having to ask the client to do it. So, I'll be using Paypal for goods which are fully paid for when the order is placed (I'll give a small discount for this) and Atos for the others. The only problem remaining is that Atos ignores the "if" statement in the php code where I ask for only orders above 200 Euros to be taken into consideration.
That's the problem in a nutshell.
Thanks
Pete
Re: PHP If...Else question
Your original code was a bit dodgy, but could have worked. That which I gave you was syntactically perfect, and would have the same effect as your original code intended but more efficiently.
However, both are clearly incomplete fragments and without more detailed knowledge of the context in which you're trying to use them and a more specific explanation of the results than "that doesn't work", there's not much I can add.
Re: PHP If...Else question
The code you gave me just produced a white page. I think the problem is with the actual payment module code. Its the Atos module which is designed for French banks. Very, very widespread in France. The problem is that its getting its order information from I don't where. I've wasted an entire month on this - I think I'll just forget the "30% downpayment on order" and bill the entire whack straight away.
Cheers
Pete
Re: PHP If...Else question
Do you have the debug utility installed so that we can see what error is being generated?
(ou il y a une méthode plus vite mais “interdite” pour gagner ces informations que j’ai recommandé hier dans le forum français !)
Re: $order->info['total']
Perhaps posting the module files as an attachment might be more useful?
BTW: Several of your multiple discussions have been merged into one
1 Attachment(s)
Re: $order->info['total']
Re: PHP If...Else question
Yes, I see you've been busy on the Zen Cart France site ! Its a pity the site isn"t updated regularly but I suppose that's down to the limited number of users of ZC in France. I was thinking of offering my services so that I could relay the users' requests here in English because a lot don't have much joy on the French-language forum.
Yes, I have the debug utility but it isn't generating any helpful errors. As I say, I don't think the problem is with the if...else statement (although it could be better !) but is more to do with the dodgy payment module itself. I've sent the file to DrByte so he can see if there's anything obviously wrong with it but if he can't find anything I'll just have to drop the issue and move on. I just hope that 1) cashing 100% of orders when the goods are not yet ready (it can take up to 2 months before goods are dispatched) is not illegal and 2) whether its not commercial suicide to ask for 100% of the payment when the goods are ordered.
Cheers
Pete
Re: PHP If...Else question
Try this:
Code:
$sips = $order->info['total'];
//code added by PK
if ($sips >= 200) {
echo $sips = $this->makeRequest($order->info['total']*0.30, $currency);
} else {
echo $sips = $this->makeRequest($order->info['total'], $currency);
}
echo '">'."\n";
//end code added by PK
or even this:
Code:
// NOT NEEDED: $sips = $order->info['total'];
//code added by PK
if ($order->info['total'] >= 200) {
echo $sips = $this->makeRequest($order->info['total']*0.30, $currency);
} else {
echo $sips = $this->makeRequest($order->info['total'], $currency);
}
echo '">'."\n";
//end code added by PK
Re: Atos Payment Module (French Users) -- need to customize payment amount
Oh boy oh boy, the first one works ! I am deeply indebted to you, many many thanks.
Cheers
Pete
Re: Atos Payment Module (French Users) -- need to customize payment amount
Everything works except discount coupons - the payment module ignores the discount completely meaning the 30% billed when the order is placed is being based on the initial order amount, ie before the reduction is applied. Not a major problem because I'll be manually billing the correct amount when the rest of the order is due but it looks a little untidy. Any ideas anyone ?
Cheers
Pete