From 1d07a02010ef577a3a1c4aa9f912ba5b4012a86a Mon Sep 17 00:00:00 2001 From: x2001corpet Date: Wed, 7 Jun 2006 17:10:02 +0000 Subject: [PATCH] adaptation geoloc pour utiliser une regle RewriteRule simple dans apache + verification de la presence des fichiers de geodesix git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@305 839d8a87-29fc-0310-9880-83ba4fa771e5 --- hooks/geoloc.inc.php | 5 ++++- templates/geoloc/index.tpl | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/hooks/geoloc.inc.php b/hooks/geoloc.inc.php index bbdd1c4..89dd7e1 100644 --- a/hooks/geoloc.inc.php +++ b/hooks/geoloc.inc.php @@ -30,7 +30,10 @@ class GeolocConfig var $icon_path = false; function use_map() { - return $this->dynamap_path != false; + static $use_map; + if (!isset($use_map)) + $use_map = $this->dynamap_path != false && is_file($this->dynamap_path) && is_file($this->icon_path); + return $use_map; } } diff --git a/templates/geoloc/index.tpl b/templates/geoloc/index.tpl index 129b152..524d589 100644 --- a/templates/geoloc/index.tpl +++ b/templates/geoloc/index.tpl @@ -64,8 +64,8 @@ Aujourd'hui {$localises} de nos camarades sont localis - - + +

Carte fournie gracieusement par Geodesix.

-- 2.1.4