You are here

function theme_uc_cart_view_form in Ubercart 7.3

Same name and namespace in other branches
  1. 5 uc_cart/uc_cart.module \theme_uc_cart_view_form()
  2. 6.2 uc_cart/uc_cart.module \theme_uc_cart_view_form()

Themes the uc_cart_view_form().

Outputs a hidden copy of the update cart button first, so pressing Enter updates the cart instead of removing an item.

Parameters

$variables: An associative array containing:

  • form: A render element representing the form.

See also

uc_cart_view_form()

File

uc_cart/uc_cart.theme.inc, line 221
Theme functions for the uc_cart module.

Code

function theme_uc_cart_view_form($variables) {
  $form =& $variables['form'];
  $output = '<div class="uc-default-submit">';
  $output .= drupal_render($form['actions']['update']);
  $output .= '</div>';
  $form['actions']['update']['#printed'] = FALSE;
  $output .= drupal_render_children($form);
  return $output;
}