how to set custom field in order and use that field in all the appropriate linked pages like order admin grid, customer my account page, order details page in admin. I want to create one field in checkout page and save that field in order details. so that i can show that field in all related order pages. I have seen the below link but no luck. https://stackoverflow.com/questions/17599566/magento-add-custom-attribute-to-order

  • Could any one please help me on this, step by step. Jun 6, 2014 at 14:27

2 Answers 2


Add an observer :


And in the mymodule/savefield/model/obsever.php file add this:

class Mymodule_Savefield_Model_Observer
    public function Savefield($observer){
        //get event data
        $event = $observer->getEvent();

                //get order
        $order = $event->getOrder();

        //set the country here
  • Where would the MyField be saved? And how can it be fetched afterwards? Oct 12, 2017 at 21:19

I wanted to add a custom field to checkout/order page and display it on front end. I found the following step by step tutorial which helped me achieve the task. This tutorial explains how to add an HTML text field, save the field in database tables and display the field in Admin View Order page. Complete code required in every step is also provided. It's a helpful resource.

  • 1
    Above link is dead
    – Garry
    Nov 11, 2016 at 21:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.