code: function (bounds) {
          bounds = this.adjustBounds(bounds);
          var mapRes = this.map.getResolution();
          var scale = Math.round((this.map.getScale() * 10000)) / 10000;
          var pX = Math.round(bounds.left / mapRes);
          var pY = -Math.round(bounds.top / mapRes);
  
          var metaX = Math.floor(pX / this.tileSize.w / this.params.metaTileSize.w) * this.tileSize.w * this.params.metaTileSize.w;
          var metaY = Math.floor(pY / this.tileSize.h / this.params.metaTileSize.h) * this.tileSize.h * this.params.metaTileSize.h;
      
          var components = [
              "/",
              this.params.map,
              "/",
              scale,
              "/",
              this.params.g.replace(/\s/g, '_'),
              "/def/t", 
              metaY,
              "/l",
              metaX,
              "/t",
              pY,
              "l",
              pX,
              ".",
              this.extension
            ];
  
          var url = this.url;
  
          if (OpenLayers.Util.isArray(url)) {
              url = this.selectUrl(components.join(''), url);
          }
          return url + components.join("");
      }
docs: Method: getURL
  
  Parameters:
  bounds - {<OpenLayers.Bounds>}
  
  Returns:
  {String} A string with the layer's url and parameters and also the
  passed-in bounds and appropriate tile size specified as
  parameters