4

I want to override the output of the order completion page. I need to include custom markup, as well as data from the order. As a matter of personal preference (and for organizational purposes), I'd rather do this in code, in my module, rather than in Rules. Can anyone point me in the right direction?

  • Are you familiar with coding in drupal using hooks and custom modules? – Ashlar Dec 30 '11 at 17:01
8

It looks like using hook_commerce_checkout_pane_info_alter(&$checkout_panes) or hook_commerce_checkout_page_info_alter(&$checkout_pages) would be the best options. There are also hooks that allow you to create your own checkout panes/pages from scratch if necessary (hook_commerce_checkout_pane_info() and hook_commerce_checkout_page_info()). I would suggest reading more about them here and checking out the specific examples (about page/pane info hook implementations) that you can find in the Drupal Commerce submodule (mostly Checkout) files.

  • 1
    Yeah, the code in commerce_checkout.checkout_pane.inc gives a good implementation example. I should be able to override the output with hook_commerce_checkout_pane_info_alter(). Thanks for the tip. – starsinmypockets Dec 31 '11 at 15:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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