我正在使用openlayers,geoserver和Extjs,我如何从geoseb的geowebcache正确访问wms层。现在我正在使用此代码
map.addLayer(
new OpenLayers.Layer.WMS(
"trivandrum","http://localhost:8080/geoserver/gwc/service/wms",{
srs:"EPSG:4030",
LAYERS:'tvm_road_colony',
Format:'image/png',
transparent:true,
tiled: true
},
{
buffer: 0,
displayOutsideMaxExtent:true,
visibility: true,
isBaseLayer: true
}
)
);
here I have got wms layer but when i try to zoom i did'nt get the layer completely how can i solve this problem? please help
答案 0 :(得分:0)
通过geowebcache访问WMS的方法是正确的。
尝试转到http://localhost:8080/geoserver/gwc/demo
,看看是否能够从那里查看图层演示。
另外几件要注意的事情 - 您使用SRS 4030 - 确保在geowebcache.xml中正确配置,因为geoserver / geowebcache不会自动检测4386和900913以外的SRS
如果这不能解决问题,你会得到任何粉红色的屏幕吗?获取截图以查看输出结果
也很有帮助