| 
					 1 2 3 4 5 6 7 8 9 10 11  | 
						<?php global $user; $quantity = 0; $order = commerce_cart_order_load($user->uid); if ($order) {     $wrapper = entity_metadata_wrapper('commerce_order', $order);     $line_items = $wrapper->commerce_line_items;     $quantity = commerce_line_items_quantity($line_items, commerce_product_line_item_types()); //これが購入数です。     $total = commerce_line_items_total($line_items);     $currency = commerce_currency_load($total['currency_code']); }  | 
					
ユーザでなくて、変数$orderはDrupal Commerceの中でかなり使いまわします。
$order変数さえあれば、数量(quantity)は習得できるようになります。
参考にさせていただいたサイト
Programmatically show number of items in Drupal Commerce shopping cart

