Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Third Party Payment Gateway Redirect
 
bluent
Jr. Member
 
Total Posts:  8
Joined:  2009-05-13
 

I have created a new module for a local payment gateway

The module shows up in Configuration > Payments
I am able to activate it and it shows in my front end.

However, now I need to pass on values by redirecting to the third-party url but I am unable to figure which files to alter for this.

I need to pass a bunch of values via a parameter to an external URL

Please help!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Incognito
Guru
 
Total Posts:  322
Joined:  2008-08-07
Michigan
 

you are probably going to want to post it to the payment gateway using curl and avoid redirect if at all possible.

 
Magento Community Magento Community
Magento Community
Magento Community
 
bstdevelopment
Member
 
Total Posts:  48
Joined:  2008-04-14
 

interesting answer ... smile some times you can’t avoid the redirect because for instance you don’t have a ssl installed and the payment data can’t be sent through a non secured connection.

it is not as hard as it looks.

1.define public function getOrderPlaceRedirectUrl() { } in your payment model

2. do your logic

3. return a controller url like so:
return Mage::getUrl(’paymentModuleName/paymentModuleName/redirect’, array(’_secure’ => true));

4. in your controller:
public function redirectAction() {
header("Location: http://xxx.com”);exit;
}

that’s it

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