<span class="price">3 AED</span> pos
$textMsg[] = $formatPrice->currency($order->getGrandTotal()).' '." pos ". $order->getPayment()->getCcStatus();
Hi,
You can use the observer "checkout_onepage_controller_success_action" and get grandtotal of the order.
this will not return you the html.
/** * Create an order in Companyname when order status match the statuses in the backend * * @param EventObserver $observer * @return void */ public function execute(EventObserver $observer){ $order = $observer->getEvent()->getOrder(); $shipping_method = $order->getShippingMethod(); $order_status = $order->getStatus(); $orderTotal = $order->getGrandTotal(); if($order_status == 'processing'){ // use your custtom api } }
Hello @AsifJalil ,
try by replacing that with below code :
$textMsg[] = strip_tags($formatPrice->currency($order->getGrandTotal())).' '." pos ". $order->getPayment()->getCcStatus();
Let me know if it works for you.
Check this out for soluion : https://magento.stackexchange.com/questions/355107/magento-2-add-span-tag-in-priceCostco Employee Site Login