cancel
Showing results for 
Search instead for 
Did you mean: 

Order email sending

Order email sending

Hello,

I am new to Magento and I am using Magento 2.

include( $_SERVER['DOCUMENT_ROOT'].'/Vendor/Magento/Sales/Model/Order/Email/Sender/OrderSender.php');
include( $_SERVER['DOCUMENT_ROOT'].'/Vendor/Magento/Sales/Model/Order.php');
 
 $orders = loadByIncrementId($id);
 send($orders,true);

Is it possible to use above code.Simpy I need to send order email to customer in my custom payment module.

 

Thank you.