add a class to page depending on order total (Drupal Commerce)?
I came up with this piece of code, which seems to work: 

function class_price_preprocess_html(&amp;$variables){
  global $user;
  $order = commerce_cart_order_load($user-&gt;uid);
  if ($order) {
    $wrapper = entity_metadata_wrapper('commerce_order', $order);
    $line_items = $wrapper-&gt;commerce_line_items;
    $total = commerce_line_items_total($line_items);
    if($total['amount']&gt;5000){
        $variables['classes_array'][] = "class-pr";          
    }
  }
}