I also went into this problem few days ago. I tried using TMS layers but  
without success. The solution I pitched on was redirecting the willed GWC  
layers to the related GeoServer layers before they are printed. It's not a  
pretty solution, but it works well!

Geoffrey


Le Mon, 19 Sep 2011 22:00:48 +0200, Ralph Dell <rd...@catawbacountync.gov>  
a écrit:

> Using the geoext PrintProvider I was unable to print layers from
> geowebcache. My other layers printed.
>
> The solution is to use OpenLayers.Layer.TMS for the geowebcache layers
> rather than OpenLayer.Layer.WMS
>
> The solution was provided by Matt Priour who graciously spent a
> non-trivial amount of time with me late one afternoon at FOSS4G.
>
> Here is the TMS layer
>
> var cities = new OpenLayers.Layer.TMS(
> 'cities_tms','http://gis.catawbacountync.gov/geoserver/gwc/service/tms/'
> ,{
>    serviceVersion: '1.0.0',           // default value
>    layername:'catawba%3Anc_cities2@EPSG%3A900913@png',
>    type:'png',
>    visibility:true,
>    isBaseLayer: false,
>    serverResolutions:[156543.03390625, 78271.516953125,
> 39135.7584765625, 19567.87923828125, 9783.939619140625,
> 4891.9698095703125, 2445.9849047851562, 1222.9924523925781,
> 611.4962261962891, 305.74811309814453,        152.87405654907226,
> 76.43702827453613, 38.218514137268066, 19.109257068634033,
> 9.554628534317017, 4.777314267158508,         2.388657133579254,
> 1.194328566789627, 0.5971642833948135, 0.29858214169740677]
>    }
> );
>
> The TMS layernames can be found under the TMS 1.0.0 document link on
> geowebcache home.
>
> Here is a link to my demo page for those who may find this information
> helpful in the future. Solving this problem was a huge help to me. I
> believe using WMTS will also provide a solution. I have not done that as
> of yet.
>
>  http://gis.catawbacountync.gov/gwc/print_gwc.html
>
>
>
>
> _______________________________________________
> Users mailing list
> Users@geoext.org
> http://www.geoext.org/cgi-bin/mailman/listinfo/users


-- 
-- 
Geoffrey BRUN

Étudiant en master SIGMA
Stagiaire au PNR du Haut-Languedoc

Hameau de Brassac
Saint-Pons de Thomières
+33 (0) 6 77 74 44 16
_______________________________________________
Users mailing list
Users@geoext.org
http://www.geoext.org/cgi-bin/mailman/listinfo/users

Reply via email to