diff --git a/uc_googleanalytics/uc_googleanalytics.module b/uc_googleanalytics/uc_googleanalytics.module
index ffbc4c7..6b48ff5 100644
--- a/uc_googleanalytics/uc_googleanalytics.module
+++ b/uc_googleanalytics/uc_googleanalytics.module
@@ -98,7 +98,7 @@ function uc_googleanalytics_display() {
  *   The JS that should be added to the page footer.
  */
 function uc_googleanalytics_ecommerce_js($order) {
-  $script = '';
+  $script = 'ga("require", "ecommerce", "ecommerce.js");';
 
   // Lookup the name of the country or default to the ID if it can't be found
   // for some reason.
@@ -132,28 +132,19 @@ function uc_googleanalytics_ecommerce_js($order) {
     'total' => $order->order_total,
     'tax' => $order->tax_total,
     'shipping' => $order->shipping_total,
-    'city' => $order->billing_city,
-    'state' => $order->billing_zone_name,
-    'country' => $order->billing_country_name,
   );
 
   // Allow modules to alter the transaction arguments.
   drupal_alter('ucga_trans', $trans, $order);
 
-  // Put the arguments into an array that is safe to implode directly.
-  $args = array(
-    '"' . $trans['order_id'] . '"',
-    drupal_json_encode($trans['store']),
-    '"' . $trans['total'] . '"',
-    '"' . $trans['tax'] . '"',
-    '"' . $trans['shipping'] . '"',
-    drupal_json_encode($trans['city']),
-    drupal_json_encode($trans['state']),
-    drupal_json_encode($trans['country']),
-  );
+  $script .= 'ga("ecommerce:addTransaction", {
+    "id": "' . $trans['order_id'] . '",
+    "affiliation": "' . drupal_json_encode($trans['store']) . '",
+    "revenue": "' . $trans['total'] . '",
+    "shipping": "' . $trans['shipping'] . '",
+    "tax": "' . $trans['tax'] . '"
+  });';
 
-  // Add the transaction line to the JS.
-  $script .= '_gaq.push(["_addTrans", ' . implode(', ', $args) . ']);';
 
   // Loop through the products on the order.
   foreach ($order->products as $product) {
@@ -186,22 +177,19 @@ function uc_googleanalytics_ecommerce_js($order) {
     // Allow modules to alter the item arguments.
     drupal_alter('ucga_item', $item, $product, $trans, $order);
 
-    // Put the arguments into an array that is safe to implode directly.
-    $args = array(
-      '"' . $item['order_id'] . '"',
-      drupal_json_encode($item['sku']),
-      drupal_json_encode($item['name']),
-      drupal_json_encode((string) $item['category']),
-      '"' . $item['price'] . '"',
-      '"' . $item['qty'] . '"',
-    );
-
     // Add the item line to the JS.
-    $script .= '_gaq.push(["_addItem", ' . implode(', ', $args) . ']);';
+    $script .= 'ga("ecommerce:addItem", {
+      "id": "' . $item['order_id'] . '",
+      "name": "' . drupal_json_encode($item['name']) . '",
+      "sku": "' . drupal_json_encode($item['sku']) . '",
+      "category": "' . drupal_json_encode((string) $item['category']) . '",
+      "price": "' . $item['price'] . '",
+      "quantity": "' . $item['qty'] . '"
+    });';
   }
 
   // Add the function to submit the transaction to GA.
-  $script .= '_gaq.push(["_trackTrans"]);';
+  $script .= 'ga("ecommerce:send");';
 
   return $script;
 }
