<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Arial, sans-serif" size="2">
<div> I am trying to display my map inside of a mappanel and ext window. Below is my code and I am using the same exact settings as a map on a different page that shows all my layers without issues. However when I add this to an ext.window and panel it loads
but no layers show up as if the zoom level/maxextent is wrong… any ideas?</div>
<div> </div>
<div> </div>
<div> </div>
<div> <script type="text/javascript"></div>
<div> </div>
<div> // begin map defintion</div>
<div> var map = new OpenLayers.Map('map',{</div>
<div> maxExtent: new OpenLayers.Bounds(-20037508.34, -20037508.34, 20037508.34, 20037508.34),</div>
<div> maxResolution: 156543.0399,</div>
<div> units: 'km',</div>
<div> projection: new OpenLayers.Projection("EPSG:900913"),</div>
<div> displayProjection: new OpenLayers.Projection("EPSG:4326")</div>
<div> }</div>
<div> ); //end of map definition</div>
<div> </div>
<div> //Base Layer - contains all base layers (everything except transit routes/bus stops)</div>
<div> var layer_Base = new OpenLayers.Layer.WMS("Base Layer", "<a href="http://ITS701X5J1/RedWMS/Request.aspx"><font color="#0000FF"><u>http://ITS701X5J1/RedWMS/Request.aspx</u></font></a>",</div>
<div> {</div>
<div> layers: ['BAS_NEIGHBOURHOOD_SHAPE,BAS_NEIGHBOURHOOD_SHAPE1,BAS_RURAL_BLOCK_LINE,BAS_RURAL_LOT_LINE,LRSV_STREET_SEGMENT,LRSV_SECONDARY_SEGMENT,WWW_PARCELS,BAS_HYDRO,BAS_CITY_BOUNDARY_LINE, Arterial,Highway,Rural_Highway,BAS_BRIDGE'],</div>
<div> format: 'image/png',</div>
<div> VERSION: "1.1.1",</div>
<div> transparent: true</div>
<div> },</div>
<div> { isBaseLayer: true,</div>
<div> singleTile: true</div>
<div> }</div>
<div> ); </div>
<div> </div>
<div> map.addLayer(layer_Base);</div>
<div> </div>
<div> //Define Map Longitude/Latitude and Start zoom levels</div>
<div> var startupLat = 52.27210;</div>
<div> var startupLon = -113.80288; </div>
<div> var startupLevel = 12;</div>
<div> var lonLat = new OpenLayers.LonLat(startupLon, startupLat).transform(new OpenLayers.Projection("EPSG:4326"), map.getProjectionObject());</div>
<div> </div>
<div> map.setCenter(lonLat,startupLevel);</div>
<div> </div>
<div> </div>
<div> var mapPanel;</div>
<div>Ext.onReady(function() {</div>
<div> new Ext.Window({</div>
<div> title: "GeoExt MapPanel Window",</div>
<div> height: 400,</div>
<div> width: 600,</div>
<div> layout: "fit",</div>
<div> items: [{</div>
<div> xtype: "gx_mappanel",</div>
<div> id: "mappanel",</div>
<div> map: map</div>
<div> }]</div>
<div> }).show();</div>
<div> </div>
<div> mapPanel = Ext.getCmp("mappanel");</div>
<div>});</script></div>
<div> </div>
<div> </div>
</font>
<DIV><P><HR>
This e-mail is intended for the original recipient(s) only. If you have received it in error, please advise the sender and delete this message.
</P></DIV>
</body>
</html>