List all payment methods in Magento

SudheerNayak

How to get a list with all available payment methods in Magento.

If for any reason you need to a get a list with all payment methods in Magento, you can do it easily by using the payment config class (app/code/core/Mage/Payment/Model/Config.php).

To get a list with all payments active and inactive:

1
$allAvailablePaymentMethods= Mage::getModel('payment/config')->getAllMethods();

To get a list with all active payment methods:

1
$allActivePaymentMethods= Mage::getModel('payment/config')->getActiveMethods();

To get a list with all credit cards that Magento supports:

1
$allCcTypes= Mage::getModel('payment/config')->getCcTypes();

View original post

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s