You are here

function piwik_reports_get_url in Piwik Reports 7.4

Same name and namespace in other branches
  1. 7.3 piwik_reports.module \piwik_reports_get_url()

Return Piwik server url.

Return value

string Stored value of Piwik server URL.

3 calls to piwik_reports_get_url()
piwik_reports_get_goals in ./piwik_reports.module
Return a list of goals active on selected site.
piwik_reports_get_sites in ./piwik_reports.module
Return a list of sites which statistic are accessible on piwik server.
piwik_reports_reports in ./piwik_reports.pages.inc
Return the $form that handles piwik reports.

File

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

Code

function piwik_reports_get_url() {
  $url = variable_get('piwik_reports_url_http', '');
  if ($url == '') {
    if (module_exists('piwik')) {
      $url = variable_get('piwik_url_http', '');
    }
  }
  if ($url == '') {
    drupal_set_message(t('Piwik server url is missing or wrong. Please ask your administrator to check Piwik Reports configuration.'), 'warning', FALSE);
  }
  return $url;
}