From 16a2afe9e30013ece5c5cca02f8c44f4d681b1ed Mon Sep 17 00:00:00 2001 From: Edmar Moretti Date: Tue, 30 Aug 2016 00:33:56 -0300 Subject: [PATCH] Correção na ferramenta filtro e colorramp. Inclusão de variável de configuração em ms_configura.php que permite bloquear ferramentas --- classesphp/classe_mapa.php | 3 ++- classesphp/mapa_controle.php | 1 + ferramentas/3d/3d.php | 1 + ferramentas/3d/dependencias.php | 4 ++++ ferramentas/agrupaelementos/dependencias.php | 4 ++++ ferramentas/agrupaelementos/exec.php | 3 ++- ferramentas/analisageometrias/dependencias.php | 4 ++++ ferramentas/animacao/dependencias.php | 4 ++++ ferramentas/animagif/dependencias.php | 4 ++++ ferramentas/animagif/exec.php | 45 +++++++++++++++++++++++++-------------------- ferramentas/animagif/index.js | 2 +- ferramentas/animagif/index.php | 2 ++ ferramentas/animagif/manutencao.php | 14 +++++++++----- ferramentas/aplicarsld/dependencias.php | 4 ++++ ferramentas/aplicarsld/upload.php | 8 +++++--- ferramentas/atalhoscamada/dependencias.php | 4 ++++ ferramentas/atalhosedicao/dependencias.php | 4 ++++ ferramentas/atalhosedicao/exec.php | 12 +++++------- ferramentas/atalhosmapa/dependencias.php | 4 ++++ ferramentas/blacklist.php | 21 +++++++++++++++++++++ ferramentas/buffer/dependencias.php | 4 ++++ ferramentas/buffer/exec.php | 3 ++- ferramentas/bufferpt/dependencias.php | 4 ++++ ferramentas/busca/dependencias.php | 4 ++++ ferramentas/buscafotos/funcoes.php | 2 ++ ferramentas/buscainde/dependencias.php | 4 ++++ ferramentas/buscarapida/index.js | 135 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----------------------------------------------------------------- ferramentas/carregakml/dependencias.php | 4 ++++ ferramentas/carregakml/exec.php | 3 ++- ferramentas/carregamapa/dependencias.php | 4 ++++ ferramentas/carregamapa/upload.php | 3 ++- ferramentas/centroide/dependencias.php | 4 ++++ ferramentas/centroide/exec.php | 3 ++- ferramentas/centromassa/dependencias.php | 4 ++++ ferramentas/centromassa/exec.php | 12 +++++------- ferramentas/cesium/kml3d.php | 2 ++ ferramentas/colourramp/index.php | 11 +++++++---- ferramentas/comentarios/index.php | 4 ++++ ferramentas/conectargeojson/dependencias.php | 4 ++++ ferramentas/conectargeojson/exec.php | 3 ++- ferramentas/conectargeorss/dependencias.php | 4 ++++ ferramentas/conectargeorss/exec.php | 3 ++- ferramentas/conectarservicos/dependencias.php | 4 ++++ ferramentas/conectarwms/listalayers.php | 3 +++ ferramentas/confluence/dependencias.php | 4 ++++ ferramentas/congelamapa/openlayers.php | 4 ++++ ferramentas/congelamapa/openlayers3.php | 4 ++++ ferramentas/convertemapakml/dependencias.php | 4 ++++ ferramentas/convertews/dependencias.php | 4 ++++ ferramentas/convertews/exec.php | 3 ++- ferramentas/cortina/dependencias.php | 4 ++++ ferramentas/dissolve/dependencias.php | 4 ++++ ferramentas/dissolve/exec.php | 3 ++- ferramentas/distanciaptpt/dependencias.php | 4 ++++ ferramentas/distanciaptpt/exec.php | 3 ++- ferramentas/editorsql/dependencias.php | 4 ++++ ferramentas/editortema/exec.php | 7 +++++-- ferramentas/etiqueta/dependencias.php | 4 ++++ ferramentas/etiqueta/exec.php | 3 ++- ferramentas/filtro/dependencias.php | 4 ++++ ferramentas/filtro/exec.php | 8 ++++++-- ferramentas/filtro/index.js | 4 ++-- ferramentas/filtroarvore/dependencias.php | 4 ++++ ferramentas/geolocal/dependencias.php | 4 ++++ ferramentas/geonames/opentouchmaps.php | 3 +++ ferramentas/googlemaps1/endereco.php | 2 ++ ferramentas/googlemaps1/index.php | 7 ++++++- ferramentas/gradecoord/dependencias.php | 4 ++++ ferramentas/gradecoord/exec.php | 3 ++- ferramentas/gradehex/dependencias.php | 4 ++++ ferramentas/gradehex/exec.php | 3 ++- ferramentas/gradepol/dependencias.php | 4 ++++ ferramentas/gradepol/exec.php | 3 ++- ferramentas/gradepontos/dependencias.php | 4 ++++ ferramentas/gradepontos/exec.php | 3 ++- ferramentas/graficointerativo1/dependencias.php | 4 ++++ ferramentas/graficointerativo1/exec.php | 3 ++- ferramentas/graficointerativo1/index.js | 2 +- ferramentas/graficotema/dependencias.php | 4 ++++ ferramentas/graficotema/exec.php | 3 ++- ferramentas/heatmap/dependencias.php | 4 ++++ ferramentas/heatmap/exec.php | 3 ++- ferramentas/html2canvas/dependencias.php | 4 ++++ ferramentas/identifica/dependencias.php | 4 ++++ ferramentas/identifica/index.js | 6 +++--- ferramentas/identifica/twitter.php | 2 ++ ferramentas/identifica/twitterplaces.php | 2 +- ferramentas/importarwmc/dependencias.php | 4 ++++ ferramentas/importarwmc/upload.php | 3 +++ ferramentas/imprimir/a4lpaisagempdf.php | 2 ++ ferramentas/imprimir/aggpng.php | 2 ++ ferramentas/imprimir/dependencias.php | 4 ++++ ferramentas/imprimir/geotif.php | 2 ++ ferramentas/imprimir/geraimagens.php | 2 ++ ferramentas/imprimir/jpeg.php | 2 ++ ferramentas/imprimir/svg.php | 2 ++ ferramentas/imprimir/swf.php | 4 ++++ ferramentas/inseregrafico/dependencias.php | 4 ++++ ferramentas/inseretxt/dependencias.php | 4 ++++ ferramentas/inserexy2/dependencias.php | 4 ++++ ferramentas/inserexy2/exec.php | 3 ++- ferramentas/legenda/dependencias.php | 4 ++++ ferramentas/legenda/exec.php | 1 + ferramentas/linhadotempo/index.php | 5 +++++ ferramentas/loginusuario/dependencias.php | 4 ++++ ferramentas/markercluster/dependencias.php | 4 ++++ ferramentas/markercluster/exec.php | 3 ++- ferramentas/markercluster/googlemaps_js.php | 1 + ferramentas/markercluster/openlayers_js.php | 1 + ferramentas/mascara/dependencias.php | 4 ++++ ferramentas/mascara/exec.php | 3 ++- ferramentas/melhorcaminho/dependencias.php | 4 ++++ ferramentas/melhorcaminho/exec.php | 3 ++- ferramentas/metaestat/editorlimites.php | 2 ++ ferramentas/metaestat/editorlimites_dependencias.php | 2 ++ ferramentas/metar/dependencias.php | 4 ++++ ferramentas/mmscale/dependencias.php | 4 ++++ ferramentas/mmscale/exec.php | 3 ++- ferramentas/mostraexten/dependencias.php | 4 ++++ ferramentas/navegapostgis/exec.php | 7 +++++-- ferramentas/navegarquivos/exec.php | 3 +++ ferramentas/nptpol/dependencias.php | 4 ++++ ferramentas/nptpol/exec.php | 3 ++- ferramentas/nuvemtags/dependencias.php | 4 ++++ ferramentas/nuvemtags/exec.php | 3 ++- ferramentas/opcoes_autoredesenha/dependencias.php | 4 ++++ ferramentas/opcoes_escala/dependencias.php | 4 ++++ ferramentas/opcoes_escala/exec.php | 3 ++- ferramentas/opcoes_fundo/dependencias.php | 4 ++++ ferramentas/opcoes_fundo/exec.php | 3 ++- ferramentas/opcoes_legenda/dependencias.php | 4 ++++ ferramentas/opcoes_legenda/exec.php | 3 ++- ferramentas/opcoes_querymap/dependencias.php | 4 ++++ ferramentas/opcoes_querymap/exec.php | 3 ++- ferramentas/opcoes_tamanho/dependencias.php | 4 ++++ ferramentas/opcoes_tamanho/exec.php | 3 ++- ferramentas/outputformat/dependencias.php | 4 ++++ ferramentas/parametrossql/dependencias.php | 4 ++++ ferramentas/perfil/dependencias.php | 4 ++++ ferramentas/pontoempoligono/dependencias.php | 4 ++++ ferramentas/pontoempoligono/exec.php | 3 ++- ferramentas/pontosdistri/dependencias.php | 4 ++++ ferramentas/pontosdistri/exec.php | 3 ++- ferramentas/preferencias/exec.php | 3 ++- ferramentas/recline/default.php | 2 ++ ferramentas/recline/tabela.php | 2 ++ ferramentas/safe.php | 7 +++++++ ferramentas/saiku/cartograma.php | 2 ++ ferramentas/salvamapa/dependencias.php | 4 ++++ ferramentas/salvamapa/geraminiatura.php | 4 +++- ferramentas/salvamapa/index.js | 1 - ferramentas/scielo/funcoes.php | 3 +++ ferramentas/selecao/exec.php | 1 + ferramentas/selecao/index.js | 10 +++++----- ferramentas/storymap/dependencias.php | 4 ++++ ferramentas/storymap/manutencao.php | 1 - ferramentas/tabela/dependencias.php | 4 ++++ ferramentas/tabela/exec.php | 3 ++- ferramentas/tabela/relatorio.php | 2 ++ ferramentas/telaremota/exec.php | 3 ++- ferramentas/telaremota/googleearth1.php | 2 ++ ferramentas/telaremota/googlemaps1.php | 10 ++++++---- ferramentas/telaremota/openlayers1.php | 3 ++- ferramentas/tipoimagem/dependencias.php | 4 ++++ ferramentas/tme/cesium.php | 3 +++ ferramentas/tme/dependencias.php | 4 ++++ ferramentas/tme/manutencao.php | 7 +++++-- ferramentas/toponimia/dependencias.php | 4 ++++ ferramentas/toponimia/exec.php | 3 ++- ferramentas/upload/upload.php | 2 ++ ferramentas/uploadarquivos/dependencias.php | 4 ++++ ferramentas/uploaddbf/dependencias.php | 4 ++++ ferramentas/uploaddbf/upload.php | 2 ++ ferramentas/uploadgpx/dependencias.php | 4 ++++ ferramentas/uploadgpx/upload.php | 2 ++ ferramentas/uploadkml/dependencias.php | 4 ++++ ferramentas/uploadkml/upload.php | 2 ++ ferramentas/vinde/dependencias.php | 4 ++++ ferramentas/vinde/wmsindejson.php | 3 +++ ferramentas/wiki/dependencias.php | 4 ++++ ferramentas/wiki/funcoes.php | 3 +++ ferramentas/wkt2layer/dependencias.php | 4 ++++ ferramentas/wkt2layer/exec.php | 3 ++- ms_configura.php | 44 ++++++++++++++++++++++++++++++++++++++++++++ 184 files changed, 736 insertions(+), 179 deletions(-) create mode 100755 ferramentas/blacklist.php diff --git a/classesphp/classe_mapa.php b/classesphp/classe_mapa.php index a3cd02f..f84bc85 100755 --- a/classesphp/classe_mapa.php +++ b/classesphp/classe_mapa.php @@ -459,7 +459,8 @@ class Mapa if (!mb_detect_encoding($f,"UTF-8",true)){ $f = mb_convert_encoding($f,"UTF-8","ISO-8859-1"); } - $ferramentas["animagif"] = json_decode($f); + $ferramentas["animagif"] = json_decode(str_replace("'",'"',$f)); + //var_dump($ferramentas["animagif"]);exit; } $temas[] = array( $oLayer->name, diff --git a/classesphp/mapa_controle.php b/classesphp/mapa_controle.php index fa2530d..aede58b 100755 --- a/classesphp/mapa_controle.php +++ b/classesphp/mapa_controle.php @@ -111,6 +111,7 @@ $tempo = microtime(1); include_once("sani_request.php"); $_pg = array_merge($_GET,$_POST); + $interface = $_pg["interface"]; $funcao = $_pg["funcao"]; $g_sid = $_pg["g_sid"]; diff --git a/ferramentas/3d/3d.php b/ferramentas/3d/3d.php index 06c50d8..d0c0051 100755 --- a/ferramentas/3d/3d.php +++ b/ferramentas/3d/3d.php @@ -1,4 +1,5 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/agrupaelementos/dependencias.php b/ferramentas/agrupaelementos/dependencias.php index cb071e5..010af67 100755 --- a/ferramentas/agrupaelementos/dependencias.php +++ b/ferramentas/agrupaelementos/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/agrupaelementos/exec.php b/ferramentas/agrupaelementos/exec.php index 2a6e001..a0221d8 100755 --- a/ferramentas/agrupaelementos/exec.php +++ b/ferramentas/agrupaelementos/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/animacao/dependencias.php b/ferramentas/animacao/dependencias.php index dcbdde2..54df542 100755 --- a/ferramentas/animacao/dependencias.php +++ b/ferramentas/animacao/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/animagif/dependencias.php b/ferramentas/animagif/dependencias.php index cab2dbd..650536b 100755 --- a/ferramentas/animagif/dependencias.php +++ b/ferramentas/animagif/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/animagif/exec.php b/ferramentas/animagif/exec.php index b63549e..2ccd2c5 100755 --- a/ferramentas/animagif/exec.php +++ b/ferramentas/animagif/exec.php @@ -26,6 +26,8 @@ if(empty($_GET)){ //http://localhost:8014/i3geo/ferramentas/animagif/exec.php?transparente=nao&legenda=sim&tema=dengue_casos_provaveis&colunat=semana_ano_epidemiologico&w=500&h=500&mapext=-74%20-32%20-34%204 //http://localhost/i3geo/ferramentas/animagif/exec.php?nulos=-,0&transparente=sim&legenda=nao&tema=_llocalianimagif&colunat=ANOCRIA&w=500&h=500&mapext=-74%20-32%20-34%204&tipocolunat=string include("../../ms_configura.php"); +include("../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); include("../../classesphp/funcoes_gerais.php"); include("../../classesphp/carrega_ext.php"); include_once (dirname(__FILE__)."/../../classesphp/sani_request.php"); @@ -35,11 +37,9 @@ $_GET = array_merge($_GET,$_POST); // if(empty($_GET["colunat"])){ $nmapa = ms_newMapObj($locaplic."/temas/".$_GET["tema"].".map"); - $layer = $nmapa->getlayerbyname($_GET["tema"]); - $animagif = $layer->getmetadata("animagif"); - $animagif = json_decode($animagif,true); + $animagif = json_decode(str_replace("'",'"',$animagif),true); $_GET["colunat"] = $animagif["colunat"]; $_GET["tempo"] = $animagif["tempo"]; $_GET["w"] = $animagif["w"]; @@ -108,6 +108,10 @@ if(!in_array($operador,array("=","<",">"))){ $nulos = explode(",",$nulos); $arqtemp = $dir_tmp."/".$nometemp; if(file_exists($arqtemp.".gif")){ + if(getimagesize($arqtemp.".gif") == false){ + echo ""; + exit; + } $gifBinary = file_get_contents($arqtemp.".gif"); //retorna o gif para o navegador header('Content-type: image/gif'); @@ -189,9 +193,6 @@ if($copyright != ""){ $label->updatefromstring("LABEL POSITION lr END"); $label->updatefromstring('LABEL STYLE GEOMTRANSFORM "labelpoly" COLOR 255 255 255 END END'); } - -// -$mapa->save($arqtemp.".map"); //adiciona ao mapa base as camadas do mapfile indicado em $tema $nmapa = ms_newMapObj($locaplic."/temas/".$tema.".map"); $numlayers = $nmapa->numlayers; @@ -217,8 +218,6 @@ for ($i=0;$i < $numlayers;$i++){ cloneInlineSymbol($layern,$nmapa,$mapa); ms_newLayerObj($mapa, $layern); } - -$mapa->save($arqtemp.".map"); //aplica a extensao geografica $layer = $mapa->getlayerbyname($tema); @@ -270,10 +269,8 @@ $o->set("imagemode",MS_IMAGEMODE_RGBA); if($transparente == "sim"){ $o->set("transparent",MS_TRUE); } - +restauraConObj($mapa,$postgis_mapa); $mapa->save($arqtemp.".map"); -$mapa = ms_newMapObj($arqtemp.".map"); -restauraCon($arqtemp.".map",$postgis_mapa); /* if(validaAcessoTemas($arqtemp.".map",false) == true){ @@ -293,8 +290,7 @@ foreach($lista as $l){ } } -//$listaunica = array("201537"); - +$mapa = ms_newMapObj($arqtemp.".map"); //cria as imagens para cada periodo $layer = $mapa->getlayerbyname($tema); @@ -306,6 +302,11 @@ if($copyright != ""){ } $mapa->moveLayerdown(0); +$mapa->save($arqtemp.".map"); +substituiCon($mapa,$postgis_mapa); +$mapa = ms_newMapObj($arqtemp.".map"); +$copyright = $mapa->getlayerbyname("copyright"); + if($copyright != ""){ $c = $copyright->getclass(0); if($vi >= 60200){ @@ -321,19 +322,23 @@ if($copyright != ""){ $imagens = array(); $duracao = array(); $objImagem = ""; + foreach($listaunica as $d){ + + $layer = $mapa->getlayerbyname($tema); if(strtoupper($colunat) == $colunat){ $filtro = "(('[$colunat]' $operador '$d'))"; - if($tipocolunat == "numerico"){ + if($tipocolunat == "numerico" || $tipocolunat == "numero"){ $filtro = "(([$colunat] $operador $d))"; } } else{ $filtro = "$colunat $operador '$d'"; - if($tipocolunat == "numerico"){ + if($tipocolunat == "numerico" || $tipocolunat == "numero"){ $filtro = "$colunat $operador $d"; } } + $layer->setfilter($filtro); $nomec = $arqtemp.$d.".png"; @@ -346,16 +351,13 @@ foreach($listaunica as $d){ $classe->title = $d; } //$mapa->save($arqtemp."teste.map"); + $mapa->save($arqtemp.".map"); if(!file_exists($nomec)){ if($objImagem == ""){ - //$mapa->save($arqtemp.".map"); - //echo $arqtemp.".map"; $objImagem = $mapa->draw(); $objImagem->saveImage($nomec); } else{ - //$mapa->save($arqtemp.".map"); - //echo $arqtemp.".map"; $i = $mapa->draw(); $objImagem->pasteImage($i,-1); $objImagem->saveImage($nomec); @@ -365,7 +367,10 @@ foreach($listaunica as $d){ $duracao[] = $tempo; //$mapa->save($arqtemp.".map");exit; } - +restauraConObj($mapa,$postgis_mapa); +$mapa->save($arqtemp.".map"); +unlink($arqtemp.".map"); +$mapa = null; //junta as imagens no gif include("../../pacotes/gifcreator/GifCreator.php"); diff --git a/ferramentas/animagif/index.js b/ferramentas/animagif/index.js index 1fe7b0a..1f785ce 100755 --- a/ferramentas/animagif/index.js +++ b/ferramentas/animagif/index.js @@ -313,7 +313,7 @@ i3GEOF.animagif = p = i3GEO.configura.locaplic + "/ferramentas/animagif/manutencao.php"; par = "&g_sid=" + i3GEO.configura.sid + "&tema=" + i3GEOF.animagif.tema - + "&animagif=" + i3GEO.util.base64encode(j) + + "&animagif=" + j + "&funcao=inclui"; retorno = diff --git a/ferramentas/animagif/index.php b/ferramentas/animagif/index.php index eab9a44..f661940 100755 --- a/ferramentas/animagif/index.php +++ b/ferramentas/animagif/index.php @@ -1,5 +1,7 @@ diff --git a/ferramentas/animagif/manutencao.php b/ferramentas/animagif/manutencao.php index d5ecf59..624efa7 100755 --- a/ferramentas/animagif/manutencao.php +++ b/ferramentas/animagif/manutencao.php @@ -1,6 +1,7 @@ getlayerbyname($tema); if($l != ""){ @@ -37,10 +40,11 @@ switch (strtoupper($funcao)) $retorno = "ok"; break; case "INCLUI": + restauraCon($map_file,$postgis_mapa); $mapa = ms_newMapObj($map_file); $l = $mapa->getlayerbyname($tema); if($l != ""){ - //$l->setmetadata("animagif",base64_decode($animagif)); + $l->setmetadata("animagif",$animagif); $mapa->save($map_file); } $arq = $locaplic."/temas/".$tema.".map"; @@ -48,7 +52,7 @@ switch (strtoupper($funcao)) $mapa = ms_newMapObj($arq); $l = $mapa->getlayerbyname($tema); if($l != ""){ - //$l->setmetadata("animagif",base64_decode($animagif)); + $l->setmetadata("animagif",str_replace("\\","'",$_POST["animagif"])); $mapa->save($arq); removeCabecalho($arq); } diff --git a/ferramentas/aplicarsld/dependencias.php b/ferramentas/aplicarsld/dependencias.php index a2bb8c9..e296aba 100755 --- a/ferramentas/aplicarsld/dependencias.php +++ b/ferramentas/aplicarsld/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/aplicarsld/upload.php b/ferramentas/aplicarsld/upload.php index 48d8aef..86c0d9c 100755 --- a/ferramentas/aplicarsld/upload.php +++ b/ferramentas/aplicarsld/upload.php @@ -9,8 +9,11 @@ if (isset($_GET["g_sid"])) {session_id($_GET["g_sid"]);} session_start(); $map_file = $_SESSION["map_file"]; -$postgis_mapa = $_SESSION["postgis_mapa"]; -require_once (dirname(__FILE__)."/../../ms_configura.php"); + +include (dirname(__FILE__)."/../../ms_configura.php"); +include("../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); + $tema = $_GET["tema"]; if(isset($logExec) && $logExec["upload"] == true){ @@ -29,7 +32,6 @@ if(isset($logExec) && $logExec["upload"] == true){ if (isset($_FILES['i3GEOaplicarsld']['name']) && strlen(basename($_FILES['i3GEOaplicarsld']['name'])) < 200 ) { //$ndir = dirname($filen); - require_once (dirname(__FILE__)."/../../ms_configura.php"); $mapa = ms_newMapObj($map_file); echo "

Carregando o arquivo...

"; $dirmap = dirname($map_file); diff --git a/ferramentas/atalhoscamada/dependencias.php b/ferramentas/atalhoscamada/dependencias.php index c173781..c5f686a 100755 --- a/ferramentas/atalhoscamada/dependencias.php +++ b/ferramentas/atalhoscamada/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/atalhosedicao/dependencias.php b/ferramentas/atalhosedicao/dependencias.php index a407e12..261a528 100755 --- a/ferramentas/atalhosedicao/dependencias.php +++ b/ferramentas/atalhosedicao/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/atalhosedicao/exec.php b/ferramentas/atalhosedicao/exec.php index 7180444..34f007a 100755 --- a/ferramentas/atalhosedicao/exec.php +++ b/ferramentas/atalhosedicao/exec.php @@ -1,5 +1,6 @@ getlayerbyname($tema); if($l != ""){ - $l->setmetadata($meta,$valor); + $l->setmetadata($_GET["meta"],$_GET["valor"]); $mapa->save($map_file); } $retorno = "ok"; break; } -if (!connection_aborted()){ - if(isset($map_file) && isset($postgis_mapa) && $map_file != "") +if(isset($map_file) && isset($postgis_mapa) && $map_file != ""){ restauraCon($map_file,$postgis_mapa); - cpjson($retorno); } -else -{exit();} +cpjson($retorno); ?> \ No newline at end of file diff --git a/ferramentas/atalhosmapa/dependencias.php b/ferramentas/atalhosmapa/dependencias.php index bded1b1..a798d85 100755 --- a/ferramentas/atalhosmapa/dependencias.php +++ b/ferramentas/atalhosmapa/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/blacklist.php b/ferramentas/blacklist.php new file mode 100755 index 0000000..b1cc27c --- /dev/null +++ b/ferramentas/blacklist.php @@ -0,0 +1,21 @@ + \ No newline at end of file diff --git a/ferramentas/buffer/dependencias.php b/ferramentas/buffer/dependencias.php index ba1b7ea..0fa8bf0 100755 --- a/ferramentas/buffer/dependencias.php +++ b/ferramentas/buffer/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/buffer/exec.php b/ferramentas/buffer/exec.php index 26bbfc6..e3ee668 100755 --- a/ferramentas/buffer/exec.php +++ b/ferramentas/buffer/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/busca/dependencias.php b/ferramentas/busca/dependencias.php index 034eeb6..aba09ec 100755 --- a/ferramentas/busca/dependencias.php +++ b/ferramentas/busca/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/buscafotos/funcoes.php b/ferramentas/buscafotos/funcoes.php index a9b5c9a..3a2b3cd 100755 --- a/ferramentas/buscafotos/funcoes.php +++ b/ferramentas/buscafotos/funcoes.php @@ -4,6 +4,8 @@ include_once (dirname(__FILE__)."/../../classesphp/sani_request.php"); $_GET = array_merge($_GET,$_POST); require_once(dirname(__FILE__)."/../../pacotes/cpaint/cpaint2.inc.php"); require_once(dirname(__FILE__)."/../../ms_configura.php"); +include("../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); require_once(dirname(__FILE__)."/../../pacotes/phpflickr/phpFlickr.php"); error_reporting(0); diff --git a/ferramentas/buscainde/dependencias.php b/ferramentas/buscainde/dependencias.php index 5c79876..42258a4 100755 --- a/ferramentas/buscainde/dependencias.php +++ b/ferramentas/buscainde/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/buscarapida/index.js b/ferramentas/buscarapida/index.js index b858f20..09baf83 100755 --- a/ferramentas/buscarapida/index.js +++ b/ferramentas/buscarapida/index.js @@ -43,103 +43,103 @@ i3GEObuscaRapida = BOX : false, /* * Property: servico - * + * * Endereço do serviço de busca que será utilizado. Esse serviço deve ser um Web Service no * padrão reconhecido pelo i3Geo. - * + * * Type: {String} - * + * * Default: {http://mapas.mma.gov.br/webservices/geonames.php} */ servico : "http://mapas.mma.gov.br/webservices/geonames.php", /* * Property: servicowms - * + * * Endereço do serviço de busca que será utilizado para retornar a representação * cartográfica do elemento encontrado. - * + * * Esse serviço deve ser um Web Service no padrão OGC com o parametro adicional "gid" indicando o id do elemento que * será mostrado na tela. - * + * * Type: {String} - * + * * Default: {http://mapas.mma.gov.br/webservices/geonameswms.php} */ servicowms : "http://mapas.mma.gov.br/webservices/geonameswms.php", /* * Property: funcaoZoom - * + * * Nome da função que será executada ao ser clicado o botão de zoom para o elemento encontrado. - * + * * O botão de zoom é mostrado logo após cada elemento encontrado na busca. - * + * * Alterando-se essa opção, pode-se executar o busca rápida como um gadget. - * + * * Veja i3GEObuscaRapida.zoom para conhecer os parametros que essa função irá receber - * + * * Type: {String} - * + * * Default: {i3GEObuscaRapida.zoom} */ funcaozoom : "i3GEObuscaRapida.zoom", /* * Property: idresultado - * + * * Id do elemento HTML que receberá o resultado da busca - * + * * Type: {String} - * + * * Default: {resultado} */ idresultado : "resultado", /* * Property: buscatemas - * + * * Indica se deve ser feita a busca na árvore de temas - * + * * Type: {boolean} - * + * * Default: {true} */ buscaemtemas : true, /* * Variable: palavra - * + * * Palavra que será buscada - * + * * Type: {String} */ palavra : "", /* * Variable: locaplic - * + * * Endereço do i3geo (url) - * + * * Type:{String} */ locaplic : "", /* * Function: inicia - * + * * Inicia a busca de uma palavra e mostra o resultado na tela - * + * * Veja: - * + * * - * + * * Parametros: - * + * * palavra {String} - palavra que será procurada - * + * * locaplic {String} - url onde o i3geo está instalado, pe, http://localhost/i3geo - * + * * resultado {Function} - função que será executada para processar o resultado da busca no servico definido em * i3GEObuscaRapida.servicowms. O default é i3GEObuscaRapida.montaResultado - * + * * servicosexternos {boolean} - indica se a busca será feita nos serviços de busca externos - * + * * temasmapa {boolean} - indica se a busca será feita nos temas existentes no mapa - * + * * google {boolean} - busca ou nao no google (so para interface com google maps) */ inicia : function(palavra, locaplic, resultado, servicosexternos, temasmapa, google) { @@ -221,11 +221,11 @@ i3GEObuscaRapida = }, /* * Function: montaResultadoTemas - * + * * Mostra o resultado da busca nos atributos dos temas existentes no mapa - * + * * Parametro: - * + * * retorno {JSON} - resultado da função i3GEO.php.buscaRapida */ montaResultadoTemas : function(retorno) { @@ -258,13 +258,13 @@ i3GEObuscaRapida = }, /* * Function: montaResultado - * + * * Mostra o resultado da busca. Esta é a função default utilizada pelo método inicia - * + * * Após o resultado ser mostrado, é feita a busca na base de temas, executando-se o método buscaemtemas - * + * * Parametro: - * + * * retorno {JSON} - resultado da função i3GEO.php.buscaRapida */ montaResultado : function(retorno) { @@ -329,13 +329,13 @@ i3GEObuscaRapida = }, /* * Function: resultadoTemas - * + * * Acrescenta nos resultados encontrados os dados localizados na base de temas do i3geo - * + * * Essa função é cahamda pelo método montaResultado - * + * * Parameters: - * + * * retorno {Json} - resultado de */ resultadoTemas : function(retorno) { @@ -368,28 +368,28 @@ i3GEObuscaRapida = }, /* * Function: zoom - * + * * Aplica a operação de zoom quando o usuário clica no botão de adição de um resultado ao * mapa. - * + * * Essa é a função default utilizada pela ferramenta, podendo ser substituída por outra se desejado. - * + * * Além de enquadrar o mapa a uma extensão geográfica específica, uma nova camada é adicionada, * mostrando o limite da ocorrência desejada. - * + * * Veja: - * + * * - * + * * Parameters: - * + * * wkt {String} - string no formato wkt que será usado para definir a abrangência do zoom - * + * * layer {String} - nome do layer existente no serviço definido em i3GEObuscaRapida.servicowms e que será adicionado * ao mapa como uma camada WMS - * + * * gid {String} - identificador que será utilizado no WMS para selecionar o elemento desejado - * + * * nm {String} - nome que será dado a camada que será adicionada ao mapa */ zoom : function(wkt, layer, gid, nm) { @@ -428,17 +428,17 @@ i3GEObuscaRapida = }, /* * Function: adicionatema - * + * * Adiciona um tema ao mapa quando a busca localiza uma ocorrência nos menus de camadas - * + * * Nesse caso, o tema é adicionado ao mapa - * + * * Veja: - * + * * - * + * * Parameters: - * + * * obj {Object dom} - objeto DOM do tipo INPUT tendo como valor o código do tema */ adicionatema : function(obj) { @@ -456,13 +456,13 @@ i3GEObuscaRapida = }, /* * Function: mostraxy - * + * * Mostra no mapa um retangulo representando a extensão geográfica de uma ocorrência encontrada na busca - * + * * Parameters: - * + * * texto {String} - coordenadas representando a extensão geográfica do elemento - * + * * tipo {string} - wkt|extent */ mostraxy : function mostraxy(texto, tipo) { @@ -493,6 +493,11 @@ i3GEObuscaRapida = return; } b = ext.split(" "); + //OL 3 + if (window.parent.i3GEO.Interface["ATUAL"] === "openlayers" && typeof window.parent.OpenLayers.Control == "undefined") { + i3GEObuscaRapida.BOX = false; + } + if(i3GEObuscaRapida.BOX === false){ i3GEObuscaRapida.BOX = window.parent.i3GEO.desenho.addBox(b[0], b[1], b[2], b[3], "boxOndeBusca"); } @@ -502,7 +507,7 @@ i3GEObuscaRapida = }, /* * Function: escondexy - * + * * Esconde o box criado com mostraxy */ escondexy : function() { diff --git a/ferramentas/carregakml/dependencias.php b/ferramentas/carregakml/dependencias.php index 241d2b6..2e95ace 100755 --- a/ferramentas/carregakml/dependencias.php +++ b/ferramentas/carregakml/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/carregakml/exec.php b/ferramentas/carregakml/exec.php index aed1b1c..e2442e5 100755 --- a/ferramentas/carregakml/exec.php +++ b/ferramentas/carregakml/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/carregamapa/upload.php b/ferramentas/carregamapa/upload.php index 8fcdcb0..5bf56cd 100755 --- a/ferramentas/carregamapa/upload.php +++ b/ferramentas/carregamapa/upload.php @@ -1,5 +1,4 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/centroide/exec.php b/ferramentas/centroide/exec.php index e419445..6625406 100755 --- a/ferramentas/centroide/exec.php +++ b/ferramentas/centroide/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/centromassa/exec.php b/ferramentas/centromassa/exec.php index 194c48c..7b04745 100755 --- a/ferramentas/centromassa/exec.php +++ b/ferramentas/centromassa/exec.php @@ -1,5 +1,6 @@ centroMassa($item); + $retorno = $m->centroMassa($_GET["item"]); $m->salva(); $_SESSION["contadorsalva"]++; break; } -if (!connection_aborted()){ - if(isset($map_file) && isset($postgis_mapa) && $map_file != "") +if(isset($map_file) && isset($postgis_mapa) && $map_file != ""){ restauraCon($map_file,$postgis_mapa); - cpjson($retorno); } -else -{exit();} +cpjson($retorno); ?> \ No newline at end of file diff --git a/ferramentas/cesium/kml3d.php b/ferramentas/cesium/kml3d.php index 550b3d2..2b780b9 100755 --- a/ferramentas/cesium/kml3d.php +++ b/ferramentas/cesium/kml3d.php @@ -1,5 +1,7 @@ listaColourRamps(dirname(__FILE__)."/../.."))); - if(!isset($ncores)) - {$ncores = 10;} + if(!isset($_GET["ncores"])){ + $_GET["ncores"] = 10; + } if(empty($_GET["locaplic"])){ - $locaplic = "../.."; + $_GET["locaplic"] = "../.."; } + + $locaplic = $_GET["locaplic"]; ?> @@ -130,7 +133,7 @@ new YAHOO.widget.Button( {onclick:{fn: function(){aplicarCores();}}} ); $i("voltar-button").style.width = "250px" -var lista = ""; +var lista = ""; lista = lista.split(","); var n = lista.length; var ins = ""; diff --git a/ferramentas/comentarios/index.php b/ferramentas/comentarios/index.php index 19f0ca5..af54493 100755 --- a/ferramentas/comentarios/index.php +++ b/ferramentas/comentarios/index.php @@ -14,6 +14,10 @@ g_sid tema - tema que será comentado */ +include("../../ms_configura.php"); +include("../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); + include (dirname(__FILE__)."/../../classesphp/sani_request.php"); $parametrosURL = array_merge($_GET,$_POST); diff --git a/ferramentas/conectargeojson/dependencias.php b/ferramentas/conectargeojson/dependencias.php index d4f13b3..3a091f6 100755 --- a/ferramentas/conectargeojson/dependencias.php +++ b/ferramentas/conectargeojson/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/conectargeojson/exec.php b/ferramentas/conectargeojson/exec.php index 5a383d8..74eba25 100755 --- a/ferramentas/conectargeojson/exec.php +++ b/ferramentas/conectargeojson/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/conectargeorss/exec.php b/ferramentas/conectargeorss/exec.php index 1a4afb1..6d503fc 100755 --- a/ferramentas/conectargeorss/exec.php +++ b/ferramentas/conectargeorss/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/conectarwms/listalayers.php b/ferramentas/conectarwms/listalayers.php index 149252e..01d06f5 100755 --- a/ferramentas/conectarwms/listalayers.php +++ b/ferramentas/conectarwms/listalayers.php @@ -5,6 +5,9 @@ * Isso pq o endereco do servico e um parametro obtido em $_GET["servico"] */ include (dirname(__FILE__)."/../../classesphp/sani_request.php"); +include(dirname(__FILE__)."../../ms_configura.php"); +include(dirname(__FILE__)."../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,true); ?> diff --git a/ferramentas/confluence/dependencias.php b/ferramentas/confluence/dependencias.php index 77f8ea9..5d64081 100755 --- a/ferramentas/confluence/dependencias.php +++ b/ferramentas/confluence/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/congelamapa/openlayers.php b/ferramentas/congelamapa/openlayers.php index 9944b01..2377317 100755 --- a/ferramentas/congelamapa/openlayers.php +++ b/ferramentas/congelamapa/openlayers.php @@ -1,5 +1,9 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/convertews/dependencias.php b/ferramentas/convertews/dependencias.php index a16b033..792d732 100755 --- a/ferramentas/convertews/dependencias.php +++ b/ferramentas/convertews/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/convertews/exec.php b/ferramentas/convertews/exec.php index ff42d44..bd79927 100755 --- a/ferramentas/convertews/exec.php +++ b/ferramentas/convertews/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/dissolve/dependencias.php b/ferramentas/dissolve/dependencias.php index a898958..967a4bd 100755 --- a/ferramentas/dissolve/dependencias.php +++ b/ferramentas/dissolve/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/dissolve/exec.php b/ferramentas/dissolve/exec.php index c1aa675..fc7843b 100755 --- a/ferramentas/dissolve/exec.php +++ b/ferramentas/dissolve/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/distanciaptpt/exec.php b/ferramentas/distanciaptpt/exec.php index 1dbfe13..11fdfd2 100755 --- a/ferramentas/distanciaptpt/exec.php +++ b/ferramentas/distanciaptpt/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/editortema/exec.php b/ferramentas/editortema/exec.php index 0cef71b..b806198 100755 --- a/ferramentas/editortema/exec.php +++ b/ferramentas/editortema/exec.php @@ -25,8 +25,11 @@ Free Software Foundation, Inc., no endereço 59 Temple Street, Suite 330, Boston, MA 02111-1307 USA. */ -include_once(dirname(__FILE__)."/../inicia.php"); include_once(dirname(__FILE__)."/../../admin/php/login.php"); + +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); + $funcoesEdicao = array( "ADICIONAGEOMETRIA", "ATUALIZAGEOMETRIA", @@ -73,7 +76,7 @@ switch (strtoupper($funcao)) $srid = -1; } } - + $dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); $dbh->beginTransaction(); diff --git a/ferramentas/etiqueta/dependencias.php b/ferramentas/etiqueta/dependencias.php index 0db2514..2dadf03 100755 --- a/ferramentas/etiqueta/dependencias.php +++ b/ferramentas/etiqueta/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/etiqueta/exec.php b/ferramentas/etiqueta/exec.php index 7ae54db..0310473 100755 --- a/ferramentas/etiqueta/exec.php +++ b/ferramentas/etiqueta/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/filtro/exec.php b/ferramentas/filtro/exec.php index 95c673e..bc6742b 100755 --- a/ferramentas/filtro/exec.php +++ b/ferramentas/filtro/exec.php @@ -1,5 +1,6 @@ insereFiltro($_GET["filtro"],$_GET["testa"],"sim");} + if(!isset($_GET["testa"])){ + $_GET["testa"]=""; + } + $m->insereFiltro(""); + $retorno = $m->insereFiltro($_GET["filtro"],$_GET["testa"],"sim"); if(strtolower($testa) != "sim"){ $m->salva(); $_SESSION["contadorsalva"]++; diff --git a/ferramentas/filtro/index.js b/ferramentas/filtro/index.js index 644e6e0..b7ffdb1 100755 --- a/ferramentas/filtro/index.js +++ b/ferramentas/filtro/index.js @@ -397,7 +397,7 @@ i3GEOF.filtro = { $i(idRetorno).value = i3GEOF.filtro.formataMapserver(); } else{ - p = i3GEO.configura.locaplic+"/ferramentas/filtro/exec.php?base64=sim&g_sid="+i3GEO.configura.sid+"&funcao=inserefiltro&filtro="+i3GEO.util.base64encode(filtro); + p = i3GEO.configura.locaplic+"/ferramentas/filtro/exec.php?base64=nao&g_sid="+i3GEO.configura.sid+"&funcao=inserefiltro&filtro="+filtro; cp = new cpaint(); cp.set_response_type("JSON"); cp.set_transfer_mode('POST'); @@ -415,7 +415,7 @@ i3GEOF.filtro = { i3GEOF.filtro.aguarde.visibility = "hidden"; }; } - cp.call(p,"insereFiltro",temp,"tema="+i3GEOF.filtro.tema,"testa="+testa); + cp.call(p,"insereFiltro",temp,"tema="+i3GEOF.filtro.tema+"&testa="+testa); } } catch(e){ diff --git a/ferramentas/filtroarvore/dependencias.php b/ferramentas/filtroarvore/dependencias.php index 3c5136a..8441ac9 100755 --- a/ferramentas/filtroarvore/dependencias.php +++ b/ferramentas/filtroarvore/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/geolocal/dependencias.php b/ferramentas/geolocal/dependencias.php index ea67250..aa3fdb5 100755 --- a/ferramentas/geolocal/dependencias.php +++ b/ferramentas/geolocal/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/geonames/opentouchmaps.php b/ferramentas/geonames/opentouchmaps.php index 728ff6a..10a3ccc 100755 --- a/ferramentas/geonames/opentouchmaps.php +++ b/ferramentas/geonames/opentouchmaps.php @@ -15,6 +15,9 @@ text-align:left; O código de barras abaixo pode ser lido por dispositivos móveis, como os celulares ou pdas."; echo "

Se o seu dispositivo possuir o software adequado, fotografe o código para abrir o navegador de internet ou clique no link."; diff --git a/ferramentas/googlemaps1/endereco.php b/ferramentas/googlemaps1/endereco.php index bd36cec..66b9f78 100755 --- a/ferramentas/googlemaps1/endereco.php +++ b/ferramentas/googlemaps1/endereco.php @@ -1,6 +1,8 @@ - + diff --git a/ferramentas/gradecoord/dependencias.php b/ferramentas/gradecoord/dependencias.php index c63a07a..419b431 100755 --- a/ferramentas/gradecoord/dependencias.php +++ b/ferramentas/gradecoord/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/gradecoord/exec.php b/ferramentas/gradecoord/exec.php index 9c93677..ae552d7 100755 --- a/ferramentas/gradecoord/exec.php +++ b/ferramentas/gradecoord/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/gradehex/exec.php b/ferramentas/gradehex/exec.php index 56376ab..646ee58 100755 --- a/ferramentas/gradehex/exec.php +++ b/ferramentas/gradehex/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/gradepol/exec.php b/ferramentas/gradepol/exec.php index 6ab974a..8a90e38 100755 --- a/ferramentas/gradepol/exec.php +++ b/ferramentas/gradepol/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/gradepontos/exec.php b/ferramentas/gradepontos/exec.php index a6845a3..a332010 100755 --- a/ferramentas/gradepontos/exec.php +++ b/ferramentas/gradepontos/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/graficotema/exec.php b/ferramentas/graficotema/exec.php index 90ba651..25ff549 100755 --- a/ferramentas/graficotema/exec.php +++ b/ferramentas/graficotema/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/heatmap/exec.php b/ferramentas/heatmap/exec.php index 16657d7..208dd40 100755 --- a/ferramentas/heatmap/exec.php +++ b/ferramentas/heatmap/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/identifica/dependencias.php b/ferramentas/identifica/dependencias.php index 728b154..e7fcc95 100755 --- a/ferramentas/identifica/dependencias.php +++ b/ferramentas/identifica/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/identifica/index.js b/ferramentas/identifica/index.js index a11a809..5ff7438 100755 --- a/ferramentas/identifica/index.js +++ b/ferramentas/identifica/index.js @@ -1168,11 +1168,11 @@ i3GEOF.identifica = i3GEOF.identifica.propJanelas[idjanela].aguarde.visibility = "hidden"; i3GEO.Interface.atualizaTema(retorno, tema); }, p = - i3GEO.configura.locaplic + "/ferramentas/filtro/exec.php?base64=sim&g_sid=" + i3GEO.configura.sid + "&funcao=inserefiltro", cp = + i3GEO.configura.locaplic + "/ferramentas/filtro/exec.php?base64=nao&g_sid=" + i3GEO.configura.sid + "&funcao=inserefiltro", cp = new cpaint(); cp.set_response_type("JSON"); cp.set_transfer_mode('POST'); - cp.call(p, "insereFiltro", temp, "tema=" + tema, "filtro=" + i3GEO.util.base64encode(filtro)); + cp.call(p, "insereFiltro", temp, "tema=" + tema + "&filtro=" + filtro); }, removeFiltro : function(tema, idjanela) { if (i3GEOF.identifica.propJanelas[idjanela].visibility === "visible") { @@ -1187,7 +1187,7 @@ i3GEOF.identifica = new cpaint(); cp.set_response_type("JSON"); cp.set_transfer_mode('POST'); - cp.call(p, "insereFiltro", temp, "tema=" + tema, "filtro="); + cp.call(p, "insereFiltro", temp, "tema=" + tema + "&filtro="); }, adicionaPontoRegiao : function(idjanela) { var p = i3GEO.configura.locaplic + "/ferramentas/editortema/exec.php?funcao=adicionaGeometria&g_sid=" + i3GEO.configura.sid, tema = diff --git a/ferramentas/identifica/twitter.php b/ferramentas/identifica/twitter.php index 27f043a..04ebbe5 100755 --- a/ferramentas/identifica/twitter.php +++ b/ferramentas/identifica/twitter.php @@ -25,6 +25,8 @@ p { echo "

Raio de km

"; include(dirname(__FILE__)."/../../classesphp/carrega_ext.php"); include(dirname(__FILE__)."/../../ms_configura.php"); + include(dirname(__FILE__)."/../blacklist.php"); + verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); $s = PHP_SHLIB_SUFFIX; if(!function_exists('curl_init')) { diff --git a/ferramentas/identifica/twitterplaces.php b/ferramentas/identifica/twitterplaces.php index 9132448..58fd0bc 100755 --- a/ferramentas/identifica/twitterplaces.php +++ b/ferramentas/identifica/twitterplaces.php @@ -21,7 +21,7 @@ if(!function_exists('curl_init')) if(!function_exists('curl_init')) {echo "curl não instalado";} include(dirname(__FILE__)."/../../ms_configura.php"); - +include(dirname(__FILE__)."/../blacklist.php"); $ch = curl_init(); curl_setopt($ch,CURLOPT_URL, 'https://api.twitter.com/oauth2/token'); diff --git a/ferramentas/importarwmc/dependencias.php b/ferramentas/importarwmc/dependencias.php index 2117b0e..bb51862 100755 --- a/ferramentas/importarwmc/dependencias.php +++ b/ferramentas/importarwmc/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/importarwmc/upload.php b/ferramentas/importarwmc/upload.php index 6c9c77e..ec8ae21 100755 --- a/ferramentas/importarwmc/upload.php +++ b/ferramentas/importarwmc/upload.php @@ -20,6 +20,9 @@ $map_file = $_SESSION["map_file"]; include_once (dirname(__FILE__)."/../../classesphp/sani_request.php"); error_reporting(0); require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); + $dirmap = dirname($map_file); $arquivo = ""; diff --git a/ferramentas/imprimir/a4lpaisagempdf.php b/ferramentas/imprimir/a4lpaisagempdf.php index 7fb7ec3..26d78ea 100755 --- a/ferramentas/imprimir/a4lpaisagempdf.php +++ b/ferramentas/imprimir/a4lpaisagempdf.php @@ -13,6 +13,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/aggpng.php b/ferramentas/imprimir/aggpng.php index bb29f28..8be4d96 100755 --- a/ferramentas/imprimir/aggpng.php +++ b/ferramentas/imprimir/aggpng.php @@ -40,6 +40,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/dependencias.php b/ferramentas/imprimir/dependencias.php index 9e4f2d7..cd31a4e 100755 --- a/ferramentas/imprimir/dependencias.php +++ b/ferramentas/imprimir/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/imprimir/geotif.php b/ferramentas/imprimir/geotif.php index f0871a0..99e465c 100755 --- a/ferramentas/imprimir/geotif.php +++ b/ferramentas/imprimir/geotif.php @@ -41,6 +41,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/geraimagens.php b/ferramentas/imprimir/geraimagens.php index 4f396ad..976fa60 100755 --- a/ferramentas/imprimir/geraimagens.php +++ b/ferramentas/imprimir/geraimagens.php @@ -11,6 +11,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/jpeg.php b/ferramentas/imprimir/jpeg.php index 8285465..084999e 100755 --- a/ferramentas/imprimir/jpeg.php +++ b/ferramentas/imprimir/jpeg.php @@ -40,6 +40,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/svg.php b/ferramentas/imprimir/svg.php index 198fba4..d3b7741 100755 --- a/ferramentas/imprimir/svg.php +++ b/ferramentas/imprimir/svg.php @@ -40,6 +40,8 @@ session_start(); $map_file = $_SESSION["map_file"]; $postgis_mapa = $_SESSION["postgis_mapa"]; require_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); // //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido // diff --git a/ferramentas/imprimir/swf.php b/ferramentas/imprimir/swf.php index 0ea6284..d535125 100755 --- a/ferramentas/imprimir/swf.php +++ b/ferramentas/imprimir/swf.php @@ -1,5 +1,9 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/inseretxt/dependencias.php b/ferramentas/inseretxt/dependencias.php index fa87c05..772af28 100755 --- a/ferramentas/inseretxt/dependencias.php +++ b/ferramentas/inseretxt/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/inserexy2/dependencias.php b/ferramentas/inserexy2/dependencias.php index 05e5a2a..76610ae 100755 --- a/ferramentas/inserexy2/dependencias.php +++ b/ferramentas/inserexy2/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/inserexy2/exec.php b/ferramentas/inserexy2/exec.php index 9dd1dcf..3b90f7e 100755 --- a/ferramentas/inserexy2/exec.php +++ b/ferramentas/inserexy2/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo @@ -6,6 +9,7 @@ * javascript i3GEOF.legenda.MUSTACHE * O template e substituido pelos valores definidos em index.js no momento da inicializacao da ferramenta */ + if(extension_loaded('zlib')){ ob_start('ob_gzhandler'); } diff --git a/ferramentas/legenda/exec.php b/ferramentas/legenda/exec.php index a2866b1..fe2e0cd 100755 --- a/ferramentas/legenda/exec.php +++ b/ferramentas/legenda/exec.php @@ -1,5 +1,6 @@ diff --git a/ferramentas/loginusuario/dependencias.php b/ferramentas/loginusuario/dependencias.php index ae32eff..c82754a 100755 --- a/ferramentas/loginusuario/dependencias.php +++ b/ferramentas/loginusuario/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/markercluster/dependencias.php b/ferramentas/markercluster/dependencias.php index 975de05..8cd7958 100755 --- a/ferramentas/markercluster/dependencias.php +++ b/ferramentas/markercluster/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/markercluster/exec.php b/ferramentas/markercluster/exec.php index c5a4764..bbaf5e8 100755 --- a/ferramentas/markercluster/exec.php +++ b/ferramentas/markercluster/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/mascara/exec.php b/ferramentas/mascara/exec.php index f92b8ce..979ffe3 100755 --- a/ferramentas/mascara/exec.php +++ b/ferramentas/mascara/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/melhorcaminho/exec.php b/ferramentas/melhorcaminho/exec.php index e2c17d1..1ddb82b 100755 --- a/ferramentas/melhorcaminho/exec.php +++ b/ferramentas/melhorcaminho/exec.php @@ -1,5 +1,6 @@ diff --git a/ferramentas/metaestat/editorlimites_dependencias.php b/ferramentas/metaestat/editorlimites_dependencias.php index 1efd471..4eaccdd 100755 --- a/ferramentas/metaestat/editorlimites_dependencias.php +++ b/ferramentas/metaestat/editorlimites_dependencias.php @@ -1,4 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/mmscale/dependencias.php b/ferramentas/mmscale/dependencias.php index 5098541..7d1953c 100755 --- a/ferramentas/mmscale/dependencias.php +++ b/ferramentas/mmscale/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/mmscale/exec.php b/ferramentas/mmscale/exec.php index 7a21279..bb206ca 100755 --- a/ferramentas/mmscale/exec.php +++ b/ferramentas/mmscale/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/navegapostgis/exec.php b/ferramentas/navegapostgis/exec.php index db3ef79..2c56e71 100755 --- a/ferramentas/navegapostgis/exec.php +++ b/ferramentas/navegapostgis/exec.php @@ -1,5 +1,9 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/nptpol/exec.php b/ferramentas/nptpol/exec.php index c0c5cef..b4d2c34 100755 --- a/ferramentas/nptpol/exec.php +++ b/ferramentas/nptpol/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/nuvemtags/exec.php b/ferramentas/nuvemtags/exec.php index 6a5f2cc..4580ef5 100755 --- a/ferramentas/nuvemtags/exec.php +++ b/ferramentas/nuvemtags/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_escala/dependencias.php b/ferramentas/opcoes_escala/dependencias.php index d39ef96..72ea0ca 100755 --- a/ferramentas/opcoes_escala/dependencias.php +++ b/ferramentas/opcoes_escala/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_escala/exec.php b/ferramentas/opcoes_escala/exec.php index 769ba06..ef65662 100755 --- a/ferramentas/opcoes_escala/exec.php +++ b/ferramentas/opcoes_escala/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_fundo/exec.php b/ferramentas/opcoes_fundo/exec.php index 1f888e5..f15d261 100755 --- a/ferramentas/opcoes_fundo/exec.php +++ b/ferramentas/opcoes_fundo/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_legenda/exec.php b/ferramentas/opcoes_legenda/exec.php index f8b697f..c417290 100755 --- a/ferramentas/opcoes_legenda/exec.php +++ b/ferramentas/opcoes_legenda/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_querymap/exec.php b/ferramentas/opcoes_querymap/exec.php index 8698e17..bcf72ab 100755 --- a/ferramentas/opcoes_querymap/exec.php +++ b/ferramentas/opcoes_querymap/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/opcoes_tamanho/exec.php b/ferramentas/opcoes_tamanho/exec.php index 7c2880b..ca1011f 100755 --- a/ferramentas/opcoes_tamanho/exec.php +++ b/ferramentas/opcoes_tamanho/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/parametrossql/dependencias.php b/ferramentas/parametrossql/dependencias.php index 4f37502..5eca4ee 100755 --- a/ferramentas/parametrossql/dependencias.php +++ b/ferramentas/parametrossql/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/pontoempoligono/dependencias.php b/ferramentas/pontoempoligono/dependencias.php index 3314d9a..dd762e9 100755 --- a/ferramentas/pontoempoligono/dependencias.php +++ b/ferramentas/pontoempoligono/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/pontoempoligono/exec.php b/ferramentas/pontoempoligono/exec.php index 51b9de8..efc7a44 100755 --- a/ferramentas/pontoempoligono/exec.php +++ b/ferramentas/pontoempoligono/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/pontosdistri/exec.php b/ferramentas/pontosdistri/exec.php index 8df87cb..4f03242 100755 --- a/ferramentas/pontosdistri/exec.php +++ b/ferramentas/pontosdistri/exec.php @@ -1,5 +1,6 @@ diff --git a/ferramentas/safe.php b/ferramentas/safe.php index 791d67b..7ca2b59 100755 --- a/ferramentas/safe.php +++ b/ferramentas/safe.php @@ -31,6 +31,7 @@ $ext = $_GET["ext"]; $funcao = $_GET["funcao"]; include_once(dirname(__FILE__)."/../classesphp/funcoes_gerais.php"); + if(isset($fingerprint) && !empty($g_sid)) { $f = explode(",",$fingerprint); if($f[0] != md5('I3GEOSEC' . $_SERVER['HTTP_USER_AGENT'] . session_id())){ @@ -39,8 +40,14 @@ if(isset($fingerprint) && !empty($g_sid)) { } } include_once(dirname(__FILE__)."/../ms_configura.php"); +include_once(dirname(__FILE__)."/blacklist.php"); include_once(dirname(__FILE__)."/../classesphp/classe_vermultilayer.php"); include_once(dirname(__FILE__)."/../classesphp/classe_estatistica.php"); + +if(isset($logExec) && $logExec["ferramentas"] == true){ + i3GeoLog("prog: ferramentas url: ".implode("&",array_merge($_GET,$_POST)),$_SESSION["dir_tmp"]); +} + // //substitui a string de conexão // diff --git a/ferramentas/saiku/cartograma.php b/ferramentas/saiku/cartograma.php index 212c9ec..b89bba6 100755 --- a/ferramentas/saiku/cartograma.php +++ b/ferramentas/saiku/cartograma.php @@ -13,6 +13,8 @@ if(!isset($dir_tmp)){ if(isset($statusFerramentas) && $statusFerramentas["saiku"] != true){ exit; } +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); //pega o filtro da sessao PHP aberta pelo i3Geo session_name("i3GeoPHP"); session_id($_POST["g_sid"]); diff --git a/ferramentas/salvamapa/dependencias.php b/ferramentas/salvamapa/dependencias.php index f79040c..ab871ab 100755 --- a/ferramentas/salvamapa/dependencias.php +++ b/ferramentas/salvamapa/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/salvamapa/geraminiatura.php b/ferramentas/salvamapa/geraminiatura.php index e7746a1..9e49fd7 100755 --- a/ferramentas/salvamapa/geraminiatura.php +++ b/ferramentas/salvamapa/geraminiatura.php @@ -7,7 +7,9 @@ * @param w * @param h */ -include_once (dirname(__FILE__)."/../../ms_configura.php"); +include_once (dirname(__FILE__)."/../../ms_configura.php"); +include(dirname(__FILE__)."/../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); include_once (dirname(__FILE__)."/../../classesphp/funcoes_gerais.php"); if (filter_var($_GET["restauramapa"], FILTER_VALIDATE_INT) === false){ diff --git a/ferramentas/salvamapa/index.js b/ferramentas/salvamapa/index.js index 7be6100..b337caf 100755 --- a/ferramentas/salvamapa/index.js +++ b/ferramentas/salvamapa/index.js @@ -98,7 +98,6 @@ i3GEOF.salvaMapa = { local = i3GEO.configura.locaplic+"/../ms_tmp"+local[1]; onde.innerHTML = "" + ""+$trad('baixaArquivo',i3GEOF.salvaMapa.dicionario)+"
" + - ""+$trad('veArquivo',i3GEOF.salvaMapa.dicionario)+"
" + ""+$trad('testaArquivo',i3GEOF.salvaMapa.dicionario)+""; } catch(erro){i3GEO.janela.tempoMsg(erro);} diff --git a/ferramentas/scielo/funcoes.php b/ferramentas/scielo/funcoes.php index 1aff2dc..8355196 100755 --- a/ferramentas/scielo/funcoes.php +++ b/ferramentas/scielo/funcoes.php @@ -1,6 +1,9 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/storymap/manutencao.php b/ferramentas/storymap/manutencao.php index 5268cc6..2d28678 100755 --- a/ferramentas/storymap/manutencao.php +++ b/ferramentas/storymap/manutencao.php @@ -1,6 +1,5 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/tabela/exec.php b/ferramentas/tabela/exec.php index 4614a57..8328698 100755 --- a/ferramentas/tabela/exec.php +++ b/ferramentas/tabela/exec.php @@ -1,5 +1,6 @@ diff --git a/ferramentas/telaremota/googlemaps1.php b/ferramentas/telaremota/googlemaps1.php index 579e7be..4768c99 100755 --- a/ferramentas/telaremota/googlemaps1.php +++ b/ferramentas/telaremota/googlemaps1.php @@ -1,5 +1,7 @@ @@ -113,10 +115,10 @@ function inicia(){ navm = false; var app = navigator.appName.substring(0,1); if (app==='N'){navn=true;}else{navm=true;} - + mapaRemoto = new google.maps.Map($i("googlemapsdiv"),{scaleControl:true}); mapaRemoto.setMapTypeId("terrain"); - + i3GeoMapOverlay = new google.maps.OverlayView(); i3GeoMapOverlay.draw = function() {}; criaLayer(); @@ -133,14 +135,14 @@ function criaLayer(){ tileSize: new google.maps.Size(256, 256), isPng: true, name: "Remoto" - }); + }); mapaRemoto.overlayMapTypes.insertAt(0, i3GEOTileO); } function zoom2ext(ext){ var ret = ext.split(" "); sw = new google.maps.LatLng(ret[1],ret[0]); ne = new google.maps.LatLng(ret[3],ret[2]); - mapaRemoto.fitBounds(new google.maps.LatLngBounds(sw,ne)); + mapaRemoto.fitBounds(new google.maps.LatLngBounds(sw,ne)); } function atualizaMapa(){ mapaRemoto.overlayMapTypes.removeAt(0); diff --git a/ferramentas/telaremota/openlayers1.php b/ferramentas/telaremota/openlayers1.php index 8b9a16c..35a7c1b 100755 --- a/ferramentas/telaremota/openlayers1.php +++ b/ferramentas/telaremota/openlayers1.php @@ -1,7 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/tme/cesium.php b/ferramentas/tme/cesium.php index 6254472..ff5678b 100755 --- a/ferramentas/tme/cesium.php +++ b/ferramentas/tme/cesium.php @@ -7,6 +7,9 @@ include (dirname(__FILE__)."/../../classesphp/sani_request.php"); include("../../classesphp/funcoes_gerais.php"); include("../../ms_configura.php"); +include("../blacklist.php"); +verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); + $nomeDoMapfileTema = dirname(__FILE__)."/../../temas/".$_GET["tema"].".map"; if(!file_exists($nomeDoMapfileTema)){ $nomeDoMapfileTema = $dir_tmp."/".$_GET["tema"].".map"; diff --git a/ferramentas/tme/dependencias.php b/ferramentas/tme/dependencias.php index e4d3afc..580bcb8 100755 --- a/ferramentas/tme/dependencias.php +++ b/ferramentas/tme/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/tme/manutencao.php b/ferramentas/tme/manutencao.php index 89741ed..8dd9441 100755 --- a/ferramentas/tme/manutencao.php +++ b/ferramentas/tme/manutencao.php @@ -1,6 +1,9 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/toponimia/exec.php b/ferramentas/toponimia/exec.php index 8d7207d..903ad75 100755 --- a/ferramentas/toponimia/exec.php +++ b/ferramentas/toponimia/exec.php @@ -1,5 +1,6 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/uploaddbf/dependencias.php b/ferramentas/uploaddbf/dependencias.php index 1b3b1a1..acc61e1 100755 --- a/ferramentas/uploaddbf/dependencias.php +++ b/ferramentas/uploaddbf/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/uploaddbf/upload.php b/ferramentas/uploaddbf/upload.php index b466a33..f95f7cd 100755 --- a/ferramentas/uploaddbf/upload.php +++ b/ferramentas/uploaddbf/upload.php @@ -33,6 +33,8 @@ if (isset($_FILES['i3GEOuploaddbffile']['name']) && strlen(basename($_FILES['i3G //$ndir = dirname($filen); require_once (dirname(__FILE__)."/../../ms_configura.php"); + include(dirname(__FILE__)."/../blacklist.php"); + verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); if(isset($logExec) && $logExec["upload"] == true){ i3GeoLog("prog: uploaddbf filename:" . $_FILES['i3GEOuploaddbffile']['name'],$dir_tmp); diff --git a/ferramentas/uploadgpx/dependencias.php b/ferramentas/uploadgpx/dependencias.php index 8c059fe..a2402cb 100755 --- a/ferramentas/uploadgpx/dependencias.php +++ b/ferramentas/uploadgpx/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/uploadgpx/upload.php b/ferramentas/uploadgpx/upload.php index c64e025..839ae5e 100755 --- a/ferramentas/uploadgpx/upload.php +++ b/ferramentas/uploadgpx/upload.php @@ -30,6 +30,8 @@ if (isset($_FILES['i3GEOuploadgpx']['name']) && strlen(basename($_FILES['i3GEOup } //$ndir = dirname($filen); require_once (dirname(__FILE__)."/../../ms_configura.php"); + include(dirname(__FILE__)."/../blacklist.php"); + verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); if(isset($logExec) && $logExec["upload"] == true){ i3GeoLog("prog: uploadgpx filename:" . $_FILES['i3GEOuploadgpx']['name'],$dir_tmp); diff --git a/ferramentas/uploadkml/dependencias.php b/ferramentas/uploadkml/dependencias.php index dd9b16f..4260c08 100755 --- a/ferramentas/uploadkml/dependencias.php +++ b/ferramentas/uploadkml/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/uploadkml/upload.php b/ferramentas/uploadkml/upload.php index ff581e6..2fac5b2 100755 --- a/ferramentas/uploadkml/upload.php +++ b/ferramentas/uploadkml/upload.php @@ -31,6 +31,8 @@ if (isset($_FILES['i3GEOuploadkml']['name']) && strlen(basename($_FILES['i3GEOup } //$ndir = dirname($filen); require_once (dirname(__FILE__)."/../../ms_configura.php"); + include(dirname(__FILE__)."/../blacklist.php"); + verificaBlFerramentas(basename(dirname(__FILE__)),$i3geoBlFerramentas,false); if(isset($logExec) && $logExec["upload"] == true){ i3GeoLog("prog: uploadkml filename:" . $_FILES['i3GEOuploadkml']['name'],$dir_tmp); diff --git a/ferramentas/vinde/dependencias.php b/ferramentas/vinde/dependencias.php index 0e665ca..b10dc31 100755 --- a/ferramentas/vinde/dependencias.php +++ b/ferramentas/vinde/dependencias.php @@ -1,4 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/vinde/wmsindejson.php b/ferramentas/vinde/wmsindejson.php index 537ea57..4ba573e 100755 --- a/ferramentas/vinde/wmsindejson.php +++ b/ferramentas/vinde/wmsindejson.php @@ -1,5 +1,8 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/wiki/funcoes.php b/ferramentas/wiki/funcoes.php index d3a68c2..9fc16a0 100755 --- a/ferramentas/wiki/funcoes.php +++ b/ferramentas/wiki/funcoes.php @@ -1,4 +1,7 @@ ou com a funcao scripttag do i3Geo diff --git a/ferramentas/wkt2layer/exec.php b/ferramentas/wkt2layer/exec.php index f311d4a..5514d38 100755 --- a/ferramentas/wkt2layer/exec.php +++ b/ferramentas/wkt2layer/exec.php @@ -1,5 +1,6 @@ true ); /* +Variable: $i3geoBlFerramentas + +Lista de ferramentas que sao bloqueadas, impedindo sua execucao. + +O bloqueio e feito da seguinte forma: + +- diretamente no programa PHP que executa as operacoes relativas a ferramenta + +- diretamente no programa que faz a carga dos javascripts necessarios ao funcionamento da ferramenta + +Essa lista nao impede que a ferramenta seja mostrada na interface do i3Geo. Para remover da interface +e necessario usar as opcoes de configuracao das inetrfaces. Mesmo a opcao sendo mostrada, ela sera +bloqueada quando o usuario tentar executa-la. + +As palavras incluidas na lista correspondem ao nome da pasta onde reside o codigo da ferramenta e +armazenada em i3geo/ferramentas. + +Exemplo: para bloquear a funcao de edicao da legenda e a funcao que mostra a tabela de +atributos, basta incluir na lista "legenda","tabela" + +$i3geoBlFerramentas = array("legenda","tabela"); + +Para nao bloquear nenhuma ferramenta, deixe em branco + +Excecoes: + +As seguintes ferramentas nao podem ser bloqueadas: +(algumas dessas ferramentas sao bloqueadas dependendo da configuracao de cada tema. Algumas +sao agregadores de outras ferramentas ou nao utilizam PHP) + +colorpicker,colourramp,convertekml,download,editorgm,editorol,excluirarvore,opacidademapa, +opcoes_autoredesenha,opcoes_label,salvamapfile,wmstime + +As seguintes ferramentas podem ser bloqueadas apenas impedindo-se a carga do javascript +(as operacoes via PHP sao realizadas por outras classes que nao residem na pasta ferramentas ou não utiliza PHP) + +analisageometrias,animacao,atalhoscamada,atalhosedicao,atalhosmapa,bufferpt,busca,buscainde +buscarapida,conectarservicos,convertemapakml,cortina,editorsql,filtroarvore,geolocal,html2canvas,inseregrafico +inseretxt,mostraexten,outputformat,perfil,tipoimagem + +*/ +$i3geoBlFerramentas = array("carregamapa"); + +/* Variable: $ogrOutput Indica se o OGR esta corretamente instalado, permitindo o seu uso nos servicos OGC de exportacao de dados -- libgit2 0.21.2