Commit a7320b170a1f2793ecf06925be63bdea4587cbbf

Authored by Edmar Moretti
1 parent 41877b0b

--no commit message

Showing 1 changed file with 7 additions and 5 deletions   Show diff stats
testamapfile.php
... ... @@ -67,6 +67,8 @@ if (!function_exists('ms_GetVersion'))
67 67 else
68 68 {dl('php_mapscript.so');}
69 69 }
  70 +$versao = versao();
  71 +$versao = $versao["principal"];
70 72 ms_ResetErrorList();
71 73 if(!isset($tipo))
72 74 {$tipo = "";}
... ... @@ -107,7 +109,7 @@ if (isset($map) && $map != "")
107 109 }
108 110 function verifica($map,$solegenda)
109 111 {
110   - global $tipo,$locaplic,$postgis_mapa;
  112 + global $tipo,$locaplic,$postgis_mapa,$versao;
111 113 if ($tipo == "mini" && file_exists('temas/miniaturas/'.$map.".mini.png"))
112 114 {
113 115 Header("Content-type: image/png");
... ... @@ -140,14 +142,14 @@ function verifica($map,$solegenda)
140 142 if ($tema != "")
141 143 {
142 144 if (strtoupper(substr(PHP_OS, 0, 3) == 'WIN'))
143   - {$mapa = ms_newMapObj("aplicmap/geral1windows.map");}
  145 + {$mapa = ms_newMapObj("aplicmap/geral1windowsv".$versao.".map");}
144 146 else
145 147 {
146   - if(file_exists('/var/www/i3geo/aplicmap/geral1debian.map')){
147   - $mapa = ms_newMapObj("aplicmap/geral1debian.map");
  148 + if(file_exists('/var/www/i3geo/aplicmap/geral1debianv'.$versao.'.map')){
  149 + $mapa = ms_newMapObj("aplicmap/geral1debianv".$versao.".map");
148 150 }
149 151 else
150   - {$mapa = ms_newMapObj("aplicmap/geral1.map");}
  152 + {$mapa = ms_newMapObj("aplicmap/geral1v".$versao.".map");}
151 153 }
152 154 if(@ms_newMapObj($tema))
153 155 {
... ...