You are here

function googleanalytics_disable in Google Analytics 6.2

Same name and namespace in other branches
  1. 5 googleanalytics.install \googleanalytics_disable()
  2. 6.4 googleanalytics.install \googleanalytics_disable()
  3. 6 googleanalytics.install \googleanalytics_disable()
  4. 6.3 googleanalytics.install \googleanalytics_disable()
  5. 7.2 googleanalytics.install \googleanalytics_disable()
  6. 7 googleanalytics.install \googleanalytics_disable()

Remove cache directory if module is disabled (or uninstalled).

File

./googleanalytics.install, line 46
Installation file for Google Analytics module.

Code

function googleanalytics_disable() {
  $path = file_directory_path() . '/googleanalytics';
  if (file_exists($path)) {
    file_delete($path . '/ga.js');
    rmdir($path);
  }
}