<div dir="ltr">Hello<br><br>i tried the exemple: <a href="http://api.geoext.org/1.0/examples/print-extent.html" target="_blank">http://api.geoext.org/1.0/examples/print-extent.html</a> (i'm using geoserver 2.1.0)<br>
<br>but i got in the pdf just the title but not the map (i joined it). with the layer <br><pre>("Tasmania", "<a href="http://demo.opengeo.org/geoserver/wms">http://demo.opengeo.org/geoserver/wms</a>",<br>
{layers: "topp:tasmania_state_boundaries"}, {singleTile: true})], <br></pre>it works, but with mine it doesn't<br><br>this is the code:<br><br>var mapPanel, printProvider;<br><br>Ext.onReady(function() {<br>
// The printProvider that connects us to the print service<br>
printProvider = new GeoExt.data.PrintProvider({<br> method: "GET", // "POST" recommended for production use<br> capabilities: printCapabilities, // from the info.json script in the html<br>
customParams: {<br> mapTitle: "Printing Demo",<br> comment: "This is a map printed from GeoExt."<br> }<br> });<br><br> var printExtent = new GeoExt.plugins.PrintExtent({<br>
printProvider: printProvider<br> });<br><br> // The map we want to print, with the PrintExtent added as item.<br> mapPanel = new GeoExt.MapPanel({<br> renderTo: "content",<br> width: 450,<br>
height: 320,<br> layers: [new OpenLayers.Layer.WMS("<div dir="ltr">province", "<a href="http://localhost:8080/geoserver/wms" target="_blank">http://localhost:8080/geoserver/wms</a>",<br>
{layers: "sf:province"}, {singleTile: true})],<br>
center: [-7.50,33.5],<br> zoom: 6,<br> plugins: [printExtent],<br> bbar: [{<br> text: "Create PDF",<br> handler: function() {<br> // the PrintExtent plugin is the mapPanel's 1st plugin<br>
mapPanel.plugins[0].print();<br> }<br> }]<br> });<br> printExtent.addPage();<br>});<br><br><br>thank you</div><br></div>