Skip to content

Instantly share code, notes, and snippets.

@mec
Created February 23, 2014 13:37
Show Gist options
  • Save mec/9171623 to your computer and use it in GitHub Desktop.
Save mec/9171623 to your computer and use it in GitHub Desktop.
Took me ages to find this, using Ubercart 3.x, you want to remove the image from the cart display. Put this in your template.php
function example_form_alter(&$form, &$form_state, $form_id) {
// Alters the cart view form at /cart.
if ($form_id == 'uc_cart_view_form') {
// Hides the image column since courses don't have product images.
$form['items']['#columns']['image']['access'] = FALSE;
// Adds the label to the product description column from the image column.
$form['items']['#columns']['desc']['cell'] = t('Products');
}
}
@mbennett127
Copy link

Thanks! This gave me just what I needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment