Try the Demo

Magento Forum

   
HOWTO iDEAL (basic) zonder redirect pagina
 
Webunity
Member
 
Total Posts:  55
Joined:  2008-06-17
 

Open het volgende bestand:
<magento_dir>\app\code\core\Mage\Ideal\Block\Basic\Redirect.php

Vervang de bestaande code:

protected function _toHtml() {
...
}

Door de volgende code:

protected function _toHtml()
    
{
        $basic 
$this->getOrder()->getPayment()->getMethodInstance();

        
$strPostData '';
        foreach (
$basic->getBasicCheckoutFormFields() as $field=>$value{
            
if ($strPostData != ''{
                $strPostData
.= '&';
            
}
            $strPostData
.= rawurlencode($field).'='.rawurlencode($value);
        
}

        $ch 
curl_init();
        
curl_setopt($chCURLOPT_URL$basic->getApiUrl());
        
curl_setopt($chCURLOPT_POST1);
        
curl_setopt($chCURLOPT_POSTFIELDS$strPostData);
        
$result curl_exec ($ch);
        
curl_close ($ch);
        return 
'';
    
}

Aangezien je toch CURL moet hebben voor Magento, leek me dit een mooiere oplossing.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Gosha
Jr. Member
 
Total Posts:  12
Joined:  2008-05-25
 

Webunity thanks voor de tip,

Kan ik op dezelfde manier _toHtml functie voor PayPal module aanpassen?

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top