<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:arial,helvetica,sans-serif;font-size:8pt">Hi,<br><br>I have an ext window that reads my getcapabilities doc. thee BBar has a button which then add the layer to the map. However, when this is added it is zoomed right the way in to the largest scale.<br><br>Why is this not working as it should?<br><br>thanks for any help...<br><br>here is the code<br><br> bbar: [{<br> text: "Add To Map",<br> handler: function() {<br> capabilitiesgrid.getSelectionModel().each(function(record) {<br> var clone = record.clone();<br>
clone.get("layer").mergeNewParams({<br> format: "image/png",<br> transparent: true<br> });<br> mapPanel.layers.add(clone);<br> map.zoomToExtent(<br> OpenLayers.Bounds.fromArray(clone.get("llbbox"))<br>
);<br> });<br> }<br> }]<br><div><br><br>yours,<br><br>Robert<br></div>
</div><br></body></html>