Commit 05b22552a304a6832a3b8461680dc0eada2b65e1
1 parent
bc23d765
Exists in
master
and in
7 other branches
ajustes em OGC para não ser necessário definir &tema
Showing
5 changed files
with
18 additions
and
12 deletions
Show diff stats
admin/admin.db
No preview for this file type
mashups/openlayers.php
ogc.htm
... | ... | @@ -82,12 +82,12 @@ function ogc_endereco(botao) |
82 | 82 | ins = "<H1>Endereço do web service:</H1>"; |
83 | 83 | var re = new RegExp(".htm", "g"); |
84 | 84 | var servico = window.location.href.replace(re,'.php?'); |
85 | - var s = "tema="+tema; | |
85 | + var s = ""; //"tema="+tema; | |
86 | 86 | if(botao.name === "metaestat"){ |
87 | - s = "id_medida_variavel="+tema.split("_")[1]; | |
87 | + s = "id_medida_variavel="+tema.split("_")[1] + "&"; | |
88 | 88 | } |
89 | 89 | if(botao.name === "mapaCadastrado"){ |
90 | - s = "restauramapa="+tema.split("_")[1]; | |
90 | + s = "restauramapa="+tema.split("_")[1] + "&"; | |
91 | 91 | tema = ""; |
92 | 92 | } |
93 | 93 | |
... | ... | @@ -95,13 +95,13 @@ function ogc_endereco(botao) |
95 | 95 | ins += "<p>"+servico; |
96 | 96 | ins += "<p>Bookmark: <span id=bm ></span>"; |
97 | 97 | ins += "<p><iframe src='http://www.facebook.com/plugins/like.php?href="+servico+"&layout=button_count&show_faces=false&width=100&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:100px; height:21px;' allowTransparency='true'></iframe>"; |
98 | - ins += "<p><a target=blank href='"+servico+"&service=wms&version=1.1.0&request=getcapabilities&layers="+tema+"' />GetCapabilities</a>"; | |
99 | - ins += "<p><a target=blank href='"+servico+"&SRS=EPSG:4618&WIDTH=500&HEIGHT=500&BBOX=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&FORMAT=image/png&service=wms&version=1.1.0&request=getmap&layers="+tema+"' />testar getmap</a>"; | |
100 | - ins += "<p><a target=blank href='"+servico+"&format=application/openlayers&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081' />visualizar com openLayers</a>"; | |
101 | - ins += "<p><a target=blank href='"+servico+"&OUTPUTFORMAT=shape-zip&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download shapefile via WFS</a>"; | |
102 | - ins += "<p><a target=blank href='"+servico+"&OUTPUTFORMAT=csv&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download CSV via WFS</a>"; | |
103 | - ins += "<p><a target=blank href='"+servico+"&OUTPUTFORMAT=kmz&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download KMZ</a>"; | |
104 | - ins += "<p><a target=blank href='"+servico+"&OUTPUTFORMAT=geojson&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />GeoJson</a>"; | |
98 | + ins += "<p><a target=blank href='"+servico+"service=wms&version=1.1.1&request=getcapabilities&layers="+tema+"' />GetCapabilities</a>"; | |
99 | + ins += "<p><a target=blank href='"+servico+"SRS=EPSG:4618&WIDTH=500&HEIGHT=500&BBOX=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&FORMAT=image/png&service=wms&version=1.1.0&request=getmap&layers="+tema+"' />testar getmap</a>"; | |
100 | + ins += "<p><a target=blank href='"+servico+"format=application/openlayers&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&layers="+tema+"' />visualizar com openLayers</a>"; | |
101 | + ins += "<p><a target=blank href='"+servico+"OUTPUTFORMAT=shape-zip&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download shapefile via WFS</a>"; | |
102 | + ins += "<p><a target=blank href='"+servico+"OUTPUTFORMAT=csv&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download CSV via WFS</a>"; | |
103 | + ins += "<p><a target=blank href='"+servico+"OUTPUTFORMAT=kmz&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />download KMZ</a>"; | |
104 | + ins += "<p><a target=blank href='"+servico+"OUTPUTFORMAT=geojson&bbox=-76.5125927,-39.3925675209,-29.5851853,9.49014852081&service=wfs&version=1.1.0&request=getfeature&layers="+tema+"' />GeoJson</a>"; | |
105 | 105 | |
106 | 106 | if(!$i("panellistaarquivos")){ |
107 | 107 | YAHOO.namespace("datadownloadLista"); | ... | ... |
ogc.php
... | ... | @@ -88,6 +88,9 @@ include(dirname(__FILE__)."/classesphp/funcoes_gerais.php"); |
88 | 88 | //para o caso da requisicao kml |
89 | 89 | if(strtolower($OUTPUTFORMAT) == "kml" || strtolower($OUTPUTFORMAT) == "kmz"){ |
90 | 90 | //http://localhost/i3geo/pacotes/kmlmapserver/kmlservice.php?request=kmz&map=_lbiomashp&typename=_lbiomashp |
91 | + if(!isset($tema) && isset($layers)){ | |
92 | + $tema = $layers; | |
93 | + } | |
91 | 94 | $urln = "pacotes/kmlmapserver/kmlservice.php?request=kmz&map=".$tema."&typename=".$tema; |
92 | 95 | header("Location:".$urln); |
93 | 96 | exit; | ... | ... |
temas/_lbiomashp.map
... | ... | @@ -7,7 +7,7 @@ MAP |
7 | 7 | METADATA |
8 | 8 | "TIP" "CD_LEGENDA" |
9 | 9 | "CLASSE" "SIM" |
10 | - "permitekmz" "nao" | |
10 | + "permitekmz" "sim" | |
11 | 11 | "ITENSDESC" "Teste de acentuação" |
12 | 12 | "TILES" "SIM" |
13 | 13 | "ESCALA" "1000000" |
... | ... | @@ -16,7 +16,7 @@ MAP |
16 | 16 | "itembuscarapida" "CD_LEGENDA" |
17 | 17 | "ITENS" "CD_LEGENDA" |
18 | 18 | "permitekml" "sim" |
19 | - "permiteogc" "nao" | |
19 | + "permiteogc" "sim" | |
20 | 20 | "transitioneffect" "SIM" |
21 | 21 | "TEMA" "Biomas shapefile (acentuação)" |
22 | 22 | END # METADATA | ... | ... |