Order Variables

I need to retrieve the Order Number and the Customer Email Address on the order confirmation page. Does anyone know what variables I would use to retrieve this information? For example, {$order_info.total} would return the order total . . . now what is the equivalent for order number and customer email (from the order)?

The order confirmation does NOT have any order data associated with it by default. That would happen when you loaded the order details page by clicking the link on the confirmation page to show order details.



You can add a “post controller” for “checkout” in your my changes addon for the 'complete' mode that will get the order_id and then assign the order data to an $order_info variable for your use in the 'dispatch=orders.complete' template.

Then how does the variable {$order_info.total} display the order total on our confirmation page? Where does this come from?

Okay, there is an $order_info variable as part of the 'complete' view. However, I do not know what it was populated with. Different 'modes' have different data depending on their needs.

Why don't you just add a {debug} statement and then you can see all the $order_info properties that are available to you on that page?



For your original question then, you would use $order_info.order_id and $order_info.email

Thanks . . . perfect!