Drupal Answers is a question and answer site for Drupal developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I use drupal 6 and ubercart 2.

I would like to change position of the checkout button on checkout/review page to the top or possibly to duplicate it (it is currently on the bottom of the page which is not very user friendly) I found a function in uc_cart.pages.inc called

function theme_uc_cart_checkout_review($panes, $form)

Inside on the bottom I found the code for review button

$output .= '<tr class="review-button-row"><td colspan="2">'. $form

However, moving the code above the table code, breaks whole page. (I tried this inside the .inc file, because adding the function inside template file, I got an error) What would be the correct way of achieving my task? Thank you

share|improve this question
up vote 1 down vote accepted

your better off targeting the checkout button via CSS than mess with ubercarts tables on checkout as the $form contains all of the other code which you would need to parse to extract the button and apply it somewhere else.

Just do a position: absolute on the button.

If your CSS isn't up to par, then I would parse the $form variable and preg_replace() it out. You'll need to have good regex skills to grab it.

share|improve this answer
Thank you, css positioning never came to my mind. That is enough for my needs. – loparr Jan 14 '13 at 22:53

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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