You are here

function theme_uc_cart_view_form in Ubercart 5

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

File

uc_cart/uc_cart.module, line 1234

Code

function theme_uc_cart_view_form($form) {
  drupal_add_css(drupal_get_path('module', 'uc_cart') . '/uc_cart.css');
  $output = '<div id="cart-form-products">' . tapir_get_table('uc_cart_view_table', $form) . '</div>';
  if (($page = variable_get('uc_continue_shopping_url', '')) != '<none>') {
    if (variable_get('uc_continue_shopping_type', 'link') == 'link') {
      $output .= '<div id="cart-form-buttons"><div id="continue-shopping-link">' . l(variable_get('uc_continue_shopping_text', t('Continue shopping')), $page) . '</div>' . drupal_render($form) . '</div>';
    }
    else {
      $button = drupal_render($form['continue_shopping']);
      $output .= '<div id="cart-form-buttons"><div id="update-checkout-buttons">' . drupal_render($form) . '</div><div id="continue-shopping-button">' . $button . '</div></div>';
    }
  }
  else {
    $output .= '<div id="cart-form-buttons">' . drupal_render($form) . '</div>';
  }
  return $output;
}