You are here

function piwik_reports_help in Piwik Reports 7.4

Same name and namespace in other branches
  1. 8 piwik_reports.module \piwik_reports_help()
  2. 6 piwik_reports.module \piwik_reports_help()
  3. 7.2 piwik_reports.module \piwik_reports_help()
  4. 7.3 piwik_reports.module \piwik_reports_help()

Implements hook_help().

File

./piwik_reports.module, line 11
Defines features and functions common to Piwik Reports.

Code

function piwik_reports_help($path, $arg) {
  global $user;
  switch ($path) {
    case arg(0) == 'admin' && arg(1) == 'reports' && arg(2) == 'piwik_reports':
      if ($user->uid && empty($user->data['piwik_reports_token_auth']) && variable_get('piwik_reports_token_auth', '') == '') {
        drupal_set_message(t('You need to configure your <em>Piwik authentication string</em> on the <a href="@user-edit">My account</a> page.', array(
          '@user-edit' => url('user/' . $user->uid . '/edit'),
        )), 'warning', FALSE);
      }
  }
}