Skip to content

Magento 2 : Styling the order success page

You can temporarily hack the core while you are developing:

In /app/code/core/Mage/Checkout/controllers/OnepageController.php edit successAction().

Comment out the line $session->clear();. Now you can make one order and refresh the page as often as you like.

If you do not even want to make an order on each browser, for example when doing cross-browser testing, you also can just initialize the session every time.

Pick an order id and a quote id from the table sales_flat_order (fields: entity_id and quote_id). For example via:

Then change the beginning of the function as follows:

and replaceINSERT_.... with the IDs.

Now you can always call checkout/onepage/success

While you are at it, you might want to test the failureAction() as well, in

The modified action would look like this

Now you can always call checkout/onepage/failure

Share via
Copy link
Powered by Social Snap