[SPIP] v3.2.1-->v3.2.3
[lhc/web/www.git] / www / plugins-dist / statistiques / inc / referenceurs.php
index 02031b3..d0d40b2 100644 (file)
@@ -3,7 +3,7 @@
 /***************************************************************************\
  *  SPIP, Systeme de publication pour l'internet                           *
  *                                                                         *
- *  Copyright (c) 2001-2016                                                *
+ *  Copyright (c) 2001-2019                                                *
  *  Arnaud Martin, Antoine Pitrou, Philippe Riviere, Emmanuel Saint-James  *
  *                                                                         *
  *  Ce programme est un logiciel libre distribue sous licence GNU/GPL.     *
@@ -69,9 +69,9 @@ function stats_show_keywords($kw_referer) {
 
        if ($url = @parse_url($kw_referer)) {
                $query = isset($url['query']) ? $url['query'] : "";
-               $host = strtolower($url['host']);
-               $path = $url['path'];
-               $scheme = $url['scheme'];
+               $host = isset($url['host']) ? strtolower($url['host']) : "";
+               $path =  isset($url['path']) ? $url['path'] : "";
+               $scheme = isset($url['scheme']) ? $url['scheme'] : "";
        } else {
                $scheme = $query = $host = $path = '';
        }