title: Cannot read property 'length' of undefined (print map with geoserver)
body: <p>am trying to work with print with geoserver geoext/ext to print a map.
  i successed to install the print plugin, since localhost:8080/geoserver/pdf/info.json?var=printCapabilities shows the print capabilities.
  THE PROBLEM: when i try to load the page with the map and the print button i get this error:</p>
  
  <pre><code>   Uncaught TypeError: Cannot read property 'length' of undefined ext-all.js:21
     Ext.extend.readRecords ext-all.js:21
     Ext.data.Store.Ext.extend.loadData ext-all.js:21
     GeoExt.data.PrintProvider.Ext.extend.loadStores PrintProvider.js:548
     GeoExt.data.PrintProvider.Ext.extend.constructor PrintProvider.js:342
     (anonymous function) TestPrint.html:22
     (anonymous function) ext-all.js:21
     b
  </code></pre>
  
  <p>i can't figure out the problem so here's my TestPrint.html:</p>
  
  <pre><code>  &lt;!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"&gt;
    &lt;html&gt;
    &lt;head&gt;
      &lt;title&gt;
         A map
      &lt;/title&gt;
  &lt;script src="../ext-3.4.1/adapter/ext/ext-base.js"" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="../ext-3.4.1/ext-all.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;link rel="stylesheet" type="text/css" href="../ext-3.4.1/resources/css/ext-all.css"&gt;
  &lt;script src="../openlayers/OpenLayers.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="../openlayers/lib/deprecated.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="../GeoExt/lib/GeoExt.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;link rel="stylesheet" type="text/css" href="../GeoExt/resources/css/geoext-all-debug.css"&gt;
  &lt;script src="http://maps.google.com/maps/api/js?v=3&amp;amp;sensor=false"&gt;&lt;/script&gt;
  
  &lt;script type="text/javascript"&gt;
  
   var mapPanel, printDialog;
  
   Ext.onReady(function() {
  // The PrintProvider that connects us to the print service
  var printProvider = new GeoExt.data.PrintProvider({   **// this is line 22**
      method: "GET", // "POST" recommended for production use
      capabilities: "http://localhost:8080/geoserver/pdf/info.json?var=printCapabilities", // provide url instead for lazy loading
      customParams: {
          mapTitle: "GeoExt Printing Demo",
          comment: "This demo shows how to use GeoExt.PrintMapPanel"
      }
  });
  
  // A MapPanel with a "Print..." button
  mapPanel = new GeoExt.MapPanel({
      renderTo: "content",
      width: 500,
      height: 350,
      map: {
          maxExtent: new OpenLayers.Bounds(
              143.835, -43.648,
              148.479, -39.574
          ),
          maxResolution: 0.018140625,
          projection: "EPSG:4326",
          units: 'degrees'
      },
      layers: [new OpenLayers.Layer.WMS("Tasmania State Boundaries",
          "http://demo.opengeo.org/geoserver/wms",
          {layers: "topp:tasmania_state_boundaries"},
          {singleTile: true, numZoomLevels: 8})],
      center: [146.56, -41.56],
      zoom: 0,
      bbar: [{
          text: "Print...",
          handler: function(){
              // A window with the PrintMapPanel, which we can use to adjust
              // the print extent before creating the pdf.
              printDialog = new Ext.Window({
                  title: "Print Preview",
                  layout: "fit",
                  width: 350,
                  autoHeight: true,
                  items: [{
                      xtype: "gx_printmappanel",
                      sourceMap: mapPanel,
                      printProvider: printProvider
                  }],
                  bbar: [{
                      text: "Create PDF",
                      handler: function(){ printDialog.items.get(0).print(); }
                  }]
              });
              printDialog.show();
          }
      }]
  });
  
   });
  
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
   &lt;div id='content'&gt;&lt;/div&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>