Commit 32cd53cba0801433195808ef66ab7a88555659c0

Authored by Edmar Moretti
1 parent ce55b534

Corrige o botão que mostra a legenda

Showing 1 changed file with 7 additions and 4 deletions   Show diff stats
mashups/openlayers.js.php
... ... @@ -229,10 +229,13 @@ i3GEOOL = {
229 229 var nlayers = layers.length;
230 230 var ins = "";
231 231 for(i=0;i<nlayers;i++){
232   - var url = layers[i].getFullRequestString({"request":"getlegendgraphic"});
233   - url = url.replace("LAYERS","LAYER");
234   - ins += "<img src='"+url+"' /><br>";
235   - }
  232 + try{
  233 + var url = layers[i].getFullRequestString({"request":"getlegendgraphic"});
  234 + url = url.replace("LAYERS","LAYER");
  235 + ins += "<img src='"+url+"' /><br>";
  236 + }
  237 + catch(e){}
  238 + }
236 239 var w = window.open()
237 240 w.document.write(ins)
238 241 w.document.close();
... ...