### Eclipse Workspace Patch 1.0
#P google_analytics
Index: googleanalytics.admin.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/google_analytics/googleanalytics.admin.inc,v
retrieving revision 1.13
diff -u -r1.13 googleanalytics.admin.inc
--- googleanalytics.admin.inc	17 Oct 2009 14:02:51 -0000	1.13
+++ googleanalytics.admin.inc	27 May 2010 19:09:39 -0000
@@ -244,6 +244,13 @@
     '#default_value' => variable_get('googleanalytics_js_scope', 'footer'),
   );
 
+  $form['advanced']['googleanalytics_anonymizeip'] = array(
+    '#type' => 'checkbox',
+    '#title' => t('Anonymize visitors IP address'),
+    '#default_value' => variable_get('googleanalytics_anonymizeip', 0),
+    '#description' => t('Tell Google Analytics to anonymize the information sent by the tracker objects by removing the last octet of the IP address prior to its storage. Note that this will slightly reduce the accuracy of geographic reporting.')
+  );
+  
   return system_settings_form($form);
 }
 
Index: googleanalytics.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/google_analytics/googleanalytics.module,v
retrieving revision 1.36
diff -u -r1.36 googleanalytics.module
--- googleanalytics.module	4 May 2010 21:56:07 -0000	1.36
+++ googleanalytics.module	27 May 2010 19:09:39 -0000
@@ -179,6 +179,10 @@
     if (!empty($codesnippet_after)) {
       $script .= $codesnippet_after;
     }
+    $anonymize_ip = variable_get('googleanalytics_anonymizeip', 0);
+    if(!empty($anonymize_ip)){
+      $script .= '_gat._anonymizeIp();';
+    }
     $script .= '} catch(err) {}';
 
     drupal_add_js($script, array('type' => 'inline', 'scope' => 'footer'));
