From 00d0011e14a8dff270776f53483a42753d495ceb Mon Sep 17 00:00:00 2001 From: x2001corpet Date: Mon, 24 Jul 2006 22:52:06 +0000 Subject: [PATCH] backport, bug fix pour geoloc avec ie en https git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@634 839d8a87-29fc-0310-9880-83ba4fa771e5 --- modules/geoloc.php | 17 +++++++---------- templates/geoloc/getData.tpl | 4 ++-- templates/geoloc/index.tpl | 24 ++++++++++++++++-------- 3 files changed, 25 insertions(+), 20 deletions(-) diff --git a/modules/geoloc.php b/modules/geoloc.php index c808fbd..35223ca 100644 --- a/modules/geoloc.php +++ b/modules/geoloc.php @@ -25,8 +25,8 @@ class GeolocModule extends PLModule { return array( 'geoloc' => $this->make_hook('default', AUTH_COOKIE), - 'geoloc/icon.php' => $this->make_hook('icon', AUTH_COOKIE), - 'geoloc/dynamap.php' => $this->make_hook('dynamap', AUTH_COOKIE), + 'geoloc/icon.swf' => $this->make_hook('icon', AUTH_COOKIE), + 'geoloc/dynamap.swf' => $this->make_hook('dynamap', AUTH_COOKIE), 'geoloc/geolocInit.php' => $this->make_hook('init', AUTH_COOKIE), 'geoloc/getCityInfos.php' => $this->make_hook('city', AUTH_COOKIE), 'geoloc/getData.php' => $this->make_hook('data', AUTH_COOKIE), @@ -74,6 +74,7 @@ class GeolocModule extends PLModule global $globals; header("Content-type: application/x-shockwave-flash"); + header("Pragma:"); if ($globals->geoloc->use_map) { readfile($globals->geoloc->icon_path); @@ -87,17 +88,10 @@ class GeolocModule extends PLModule { global $globals; - $querystring = $this->_make_qs(); - $initfile = urlencode('geolocInit.php?'.$querystring); - - if (urlencode(Env::v('initfile')) != $initfile) { - header("Location: dynamap.php?initfile=$initfile{$querystring}"); - die(); - } - header("Content-type: application/x-shockwave-flash"); if ($globals->geoloc->use_map) { + header("Pragma:"); readfile($globals->geoloc->dynamap_path); exit; } @@ -112,6 +106,7 @@ class GeolocModule extends PLModule $page->changeTpl('geoloc/geolocInit.tpl', NO_SKIN); header('Content-type: text/xml'); + header('Pragma:'); $page->assign('querystring', $this->_make_qs()); } @@ -120,6 +115,7 @@ class GeolocModule extends PLModule global $globals; header("Content-type: text/xml"); + header("Pragma:"); $page->changeTpl('geoloc/getCityInfos.tpl', NO_SKIN); @@ -152,6 +148,7 @@ class GeolocModule extends PLModule $page->changeTpl('geoloc/getData.tpl', SIMPLE); } else { header("Content-type: text/xml"); + header("Pragma:"); $page->changeTpl('geoloc/getData.tpl', NO_SKIN); } diff --git a/templates/geoloc/getData.tpl b/templates/geoloc/getData.tpl index 81a1918..d884cd3 100644 --- a/templates/geoloc/getData.tpl +++ b/templates/geoloc/getData.tpl @@ -29,7 +29,7 @@ {if $country.nbPop > 0 or $country.id eq 0} - + {/if} @@ -38,7 +38,7 @@ {foreach from=$cities item="city"} - + {/foreach} diff --git a/templates/geoloc/index.tpl b/templates/geoloc/index.tpl index 8d0983e..f25d38d 100644 --- a/templates/geoloc/index.tpl +++ b/templates/geoloc/index.tpl @@ -57,20 +57,28 @@ function searchMapId(f) {/if} -{if !$dynamap_vars and $localises} +{if $localises}

Aujourd'hui {$localises} de nos camarades sont localisés grâce à leurs adresses personnelles.

{/if} {if $globals->geoloc->use_map}

- - - - - - - +

Carte fournie gracieusement par Geodesix.

{if !$no_annu} -- 2.1.4