O'Reilly logo

Magento 2 Developer's Guide by Branko Ajzele

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Custom offline payment methods

Magento provides several out-of-the-box offline payment methods, such as Banktransfer, Cashondelivery, Checkmo, and Purchaseorder. You can see them in the vendor/magento/module-offline-payments/Model directory.

When it comes to payment methods, it is more common to use an online payment provider (gateway), such as PayPal or Braintree. Sometimes, project requirements may be such that we may need a custom coded payment method. You will need to think of programmatic product import and order creation script that might specialize in some specifically labeled payment method. Thus, the payment process will be controlled by us.

In such cases, knowing how to code our own offline payment method might come in handy. It is worth ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required