<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content=text/html;charset=iso-8859-1>
<META content="MSHTML 6.00.6002.18357" name=GENERATOR></HEAD>
<BODY id=MailContainerBody
style="PADDING-RIGHT: 10px; PADDING-LEFT: 10px; PADDING-TOP: 15px" leftMargin=0
topMargin=0 CanvasTabStop="true" name="Compose message area">
<DIV><FONT face=Arial size=2>don’t bother with all that resolution and scale
setting (which by the way, if the map was really listening to, would need to
match up, but resolutions take precedence over scales)</FONT></DIV>
<DIV><FONT face=Arial size=2>The base layer (if you are using a base layer) will
set the map resolution.</FONT></DIV>
<DIV><FONT face=Arial size=2>You should set the maxExtent and maxResolution of
the map to reasonable levels.</FONT></DIV>
<DIV><FONT face=Arial size=2>It would be more helpful to see the bit of code
which failed, not the one that works</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Matt Priour</FONT></DIV>
<DIV><FONT face=Arial size=2>Kestrel Computer Consulting</FONT></DIV>
<DIV style="FONT: 10pt Tahoma">
<DIV><BR></DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV style="font-color: black"><B>From:</B> <A title=specjal@gmail.com
href="mailto:specjal@gmail.com">konto gmail</A> </DIV>
<DIV><B>Sent:</B> Thursday, March 17, 2011 5:29 AM</DIV>
<DIV><B>To:</B> <A title=users@geoext.org
href="mailto:users@geoext.org">users@geoext.org</A> </DIV>
<DIV><B>Subject:</B> [Users] GeoExt.plugins.PrintPageField and first
map.addLayers ...don't see any vector extend.</DIV></DIV></DIV>
<DIV><BR></DIV>Hi<BR><BR>I try to add some print extend vector layer to my map.
When i add<BR>first layer to map (which is OpenLayers.Layer.OSM() ) , my
print<BR>extend layer is visible...but when i try to add another (which
has<BR>maxzoom > 18 ) my print extend layer don't show.<BR><BR>Question: How
should look like code who will add my wms layer as basic<BR>layer. I think that
Geoext need some extra info (resolution, bounds<BR>etc).<BR><BR><BR><BR>Sample
code - it works - but how to add another WMS layer (replace OSM
layer)<BR><BR><BR>var mapnik = new OpenLayers.Layer.OSM()<BR><BR><BR> var
options = {<BR> projection: new
OpenLayers.Projection("EPSG:900913"), //2177<BR>//4326
//900913<BR> displayProjection:new
OpenLayers.Projection("EPSG:4326"),<BR>
resolutions: [156543.03390625, 78271.516953125,<BR>39135.7584765625,
19567.87923828125, 9783.939619140625,<BR>4891.9698095703125, 2445.9849047851562,
1222.9924523925781,<BR>611.4962261962891, 305.74811309814453,
152.87405654907226,<BR>76.43702827453613, 38.218514137268066,
19.109257068634033,<BR>9.554628534317017, 4.777314267158508,
2.388657133579254,<BR>1.194328566789627, 0.5971642833948135,
0.29858214169740677,<BR>0.14929107084870338, 0.07464553542435169,
0.037322767712175846,<BR>0.018661383856087923, 0.009330691928043961,
0.004665345964021981],<BR>
scales:[100000.0,75000.0,50000.0,25000.0,20000.0,15000.0,10000.0,5000.0],<BR>
units: "meters",<BR> maxExtent:
bounds,<BR> controls:
[<BR> new
OpenLayers.Control.Navigation(),<BR>
new
OpenLayers.Control.PanZoomBar(),<BR>
new
OpenLayers.Control.AiMousePosition()<BR>
//new
OpenLayers.Control.OverviewMap()<BR>
],<BR> eventListeners :
{<BR>
"moveend" : function()
{<BR>
printPage.setCenter(new<BR>OpenLayers.LonLat(map.getCenter().lon,map.getCenter().lat));<BR>
}<BR> }<BR>
};<BR><BR><BR> map = new OpenLayers.Map('map',
options);<BR> map.addLayers([mapnik]);<BR>
mapnik.setVisibility(false);<BR><BR><BR>it works
fine<BR>_______________________________________________<BR>Users mailing
list<BR><A href="mailto:Users@geoext.org">Users@geoext.org</A><BR><A
href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</A><BR></BODY></HTML>