Hello, <div><br></div><div>I've included to my HTML OpenLayers page a WMS Layer with Google maps API as a Base Layer. The former is only visible when the map is zoomed to its max extent. Why is happening that? I've posted the code below. </div>
<div><br></div><div>Thank you very much.</div><div><br></div><div><div><!DOCTYPE html></div><div><html lang='en'></div><div><head></div><div><span class="Apple-tab-span" style="white-space:pre">  </span><meta charset='utf-8' /></div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span> <title>NoGAP archaeological project</title></div><div><span class="Apple-tab-span" style="white-space:pre">     </span><script type='text/javascript' src='OpenLayers.js'></script></div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span><script src="<a href="http://maps.google.com/maps/api/js?v=3&sensor=true">http://maps.google.com/maps/api/js?v=3&sensor=true</a>"></script></div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span><style type="text/css"></div><div><span class="Apple-tab-span" style="white-space:pre">      </span>#tituloPagina {</div><div><span class="Apple-tab-span" style="white-space:pre">                      </span>font-family: Verdana, calibri;</div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span>font-size: 1.2em;</div><div><span class="Apple-tab-span" style="white-space:pre">                    </span>font-weight: normal;</div><div><span class="Apple-tab-span" style="white-space:pre">                 </span>color: #FF000000;</div>
<div><span class="Apple-tab-span" style="white-space:pre">              </span>}</div><div><span class="Apple-tab-span" style="white-space:pre">            </span>body {</div><div>                font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;</div>
<div>                font-size: small;</div><div>        }</div><div><span class="Apple-tab-span" style="white-space:pre">              </span>#map_element {</div><div>            clear: both;</div><div>            position: relative;</div>
<div>            width: 1000px;</div><div>            height: 491px;</div><div>            </div><div>            }</div><div><span class="Apple-tab-span" style="white-space:pre">             </span> #wrapper {</div><div>                width: 512px;</div>
<div>            }</div><div>            </div><div>            #location {</div><div>                float:left ;</div><div>            }</div><div>            </div><div>            #options {</div><div>                position: absolute;</div>
<div>                left: 13px;</div><div>                top: 7px;</div><div>                z-index: 3000;</div><div>            }</div><div><span class="Apple-tab-span" style="white-space:pre">           </span> /* Styles used by the default GetFeatureInfo output, added to make IE happy */</div>
<div>            table.featureInfo, table.featureInfo td, table.featureInfo th {</div><div>                border: 1px solid #ddd;</div><div>                border-collapse: collapse;</div><div>                margin: 0;</div>
<div>                padding: 0;</div><div>                font-size: 90%;</div><div>                padding: .2em .1em;</div><div>            }</div><div>            </div><div>            table.featureInfo th {</div><div>
                padding: .2em .2em;</div><div>                text-transform: uppercase;</div><div>                font-weight: bold;</div><div>                background: #eee;</div><div>            }</div><div>            </div>
<div>            table.featureInfo td {</div><div>                background: #fff;</div><div>            }</div><div>            </div><div>            table.featureInfo tr.odd td {</div><div>                background: #eee;</div>
<div>            }</div><div>            </div><div>            table.featureInfo caption {</div><div>                text-align: left;</div><div>                font-size: 100%;</div><div>                font-weight: bold;</div>
<div>                text-transform: uppercase;</div><div>                padding: .2em .2em;</div><div>            }</div><div><span class="Apple-tab-span" style="white-space:pre">       </span></style></div><div><span class="Apple-tab-span" style="white-space:pre">       </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span><script type='text/javascript'></div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">               </span>var map;</div><div><span class="Apple-tab-span" style="white-space:pre">     </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">              </span></div><div><span class="Apple-tab-span" style="white-space:pre">             </span>function init() {</div><div><span class="Apple-tab-span" style="white-space:pre">                    </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>var bounds = new OpenLayers.Bounds(</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>14000, 305900,</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>277000, 610500</div><div><span class="Apple-tab-span" style="white-space:pre">                               </span>);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span>var options = {</div><div>                controls: [],</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>maxExtent: bounds,</div>
<div>                maxResolution: 421.69235913287775,</div><div>                projection: "EPSG:4326",</div><div>                units: 'm'</div><div>            };</div><div><span class="Apple-tab-span" style="white-space:pre">              </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">              </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>map = new OpenLayers.Map('map_element', {});</div><div><span class="Apple-tab-span" style="white-space:pre">                 </span>map.addControl(new OpenLayers.Control.LayerSwitcher());</div>
<div>            map.addControl(new OpenLayers.Control.Navigation());</div><div>            map.addControl(new OpenLayers.Control.Scale($('scale')));</div><div>          </div><div><span class="Apple-tab-span" style="white-space:pre">                  </span>map.addControl (new OpenLayers.Control.Attribution());</div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>map.addControl(new OpenLayers.Control.MousePosition({element: $('location')}));</div>
<div><br></div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">                    </span>gphy = new OpenLayers.Layer.Google(</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>"Google Physical",</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>{type: google.maps.MapTypeId.TERRAIN}</div><div><span class="Apple-tab-span" style="white-space:pre">                                </span>// used to be {type: G_PHYSICAL_MAP}</div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span>);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span>gmap = new OpenLayers.Layer.Google(</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>"Google Streets", // the default</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>{numZoomLevels: 20}</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>// default type, no change needed here</div><div><span class="Apple-tab-span" style="white-space:pre">                       </span>);</div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span>ghyb = new OpenLayers.Layer.Google(</div><div><span class="Apple-tab-span" style="white-space:pre">                          </span>"Google Hybrid",</div><div><span class="Apple-tab-span" style="white-space:pre">                           </span>{type: google.maps.MapTypeId.HYBRID, numZoomLevels: 20}</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>// used to be {type: G_HYBRID_MAP, numZoomLevels: 20}</div><div><span class="Apple-tab-span" style="white-space:pre">                        </span>);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span>gsat = new OpenLayers.Layer.Google(</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>"Google Satellite",</div><div><span class="Apple-tab-span" style="white-space:pre">                                </span>{type: google.maps.MapTypeId.SATELLITE, numZoomLevels: 22}</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>// used to be {type: G_SATELLITE_MAP, numZoomLevels: 22}</div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>nogap = new OpenLayers.Layer.WMS(</div><div><span class="Apple-tab-span" style="white-space:pre">                            </span>'NoGAP Settlements',</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>'<a href="http://localhost:8080/geoserver/NoGAP_webgis/wms">http://localhost:8080/geoserver/NoGAP_webgis/wms</a>',</div><div><span class="Apple-tab-span" style="white-space:pre">                             </span>   {</div>
<div>                        layers:"NoGAP_webgis:NoGAP_Sites_oct2011",</div><div>                        transparent: true, </div><div>                        </div><div>                    },{</div><div>                        isBaseLayer: false,</div>
<div>                        controls: [],</div><div>                        maxExtent: bounds,</div><div>                     </div><div>                        projection: "EPSG:4326",</div><div>                        units: 'm'</div>
<div>                    }</div><div><span class="Apple-tab-span" style="white-space:pre">                  </span>);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span></div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">                    </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span></div>
<div><span class="Apple-tab-span" style="white-space:pre">                      </span>map.addLayers([nogap, gphy, gmap, gsat, ghyb]);</div><div><span class="Apple-tab-span" style="white-space:pre">              </span></div><div><span class="Apple-tab-span" style="white-space:pre">                     </span>if(!map.getCenter()){</div>
<div><span class="Apple-tab-span" style="white-space:pre">                              </span>map.zoomToMaxExtent();</div><div><span class="Apple-tab-span" style="white-space:pre">                       </span> map.setCenter(new OpenLayers.LonLat( 71,23 ).transform(</div>
<div><span class="Apple-tab-span" style="white-space:pre">              </span>        new OpenLayers.Projection("EPSG:4326"),</div><div><span class="Apple-tab-span" style="white-space:pre">            </span>        map.getProjectionObject()</div>
<div><span class="Apple-tab-span" style="white-space:pre">              </span>    ), 7);</div><div><span class="Apple-tab-span" style="white-space:pre">                   </span>    // add behavior to html</div><div>    var animate = document.getElementById("animate");</div>
<div>    animate.onclick = function() {</div><div>        for (var i=map.layers.length-1; i>=0; --i) {</div><div>            map.layers[i].animationEnabled = this.checked;</div><div>        }</div><div>    };</div><div>
}</div><div><span class="Apple-tab-span" style="white-space:pre"> </span></div><div><span class="Apple-tab-span" style="white-space:pre">     </span>}</div><div><span class="Apple-tab-span" style="white-space:pre">    </span></script></div>
<div></head></div><div><br></div><div><body onload='init();'></div><div><span class="Apple-tab-span" style="white-space:pre">     </span><p id="tituloPagina">NoGAP archaeological survey</p></div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span><div id='map_element' style='width: 1000px; height: 500px;'></div><div><span class="Apple-tab-span" style="white-space:pre">   </span></div></div>
<div></body></div><div></html></div><div><br></div>-- <br><font face="arial narrow, sans-serif" color="#333333">José Luis Mateos González</font><br>
</div>