How can I fetch Order URL on frontend just like its done in Customer Account dashboard > My Orders
?
The code written in history.phtml
file for Order URL
is as under:
<span class="nobr"><a href="<?php echo $this->getViewUrl($_order) ?>"><?php echo $this->__('View Order') ?></a>
How can I call the function getVIewUrl()
and pass my order_id to fetch the Order URL ?
I do not want to use BaseUrl()
and then append sales/order/view/order/id/$orderId
.
Please Help
Thanks
Best Answer
Use this: