On Fri, Oct 24, 2008 at 04:26:47AM -0700, S.Reena wrote: > > Hi , > > I have made this layer in init() which I am calling when body loads in > map.html > > wms[8] = new OpenLayers.Layer.WMS.Untiled( > > "query1","http://gis.rtbi-iitm.in/cgi-bin/mapserv?map=/var/www/html/v2/mapfile/query1.map", > > {'layers':"query1",'transparent':"true"},{'displayInLayerSwitcher':true},{'isBaseLayer':false}); > > wms[8].setVisibility(false); > > This mapfile uses query table in database. > > I have used map div for map and call a php page on a div 'popup' so that it > makes 'map' div hidden and after the table creation it makes 'popup' div > hidden and makes 'map' div visible so that they both can come one onto the > other. > > Now in some other function showmap() I am changing that query table using > php and making > > wms[8]. setVisibility(true) , but the thing is that it doesn't reflects the > new changes in table to map as layer is created previously and the changes > are made on map only if I move up the panzoombar and then come down. I tried > making this layer in showmap() instead of init() but didn't work. Also > wms[8].reload() doesn't work ....Is there any way out I can reload init() > and then display the layer in showmap() so that on calling showmap() ..map > is reloaded and wms[8] is made visible.
This is a very confusing paragraph to me. I believe what you're asking is "When I call setVisibility(true), my tiles don't update to represent what is on the server." If this is the case, then you need wms_layer.reload(true) (and OL 2.6+), which forces itself around the broser cache, I expect. Regards, -- Christopher Schmidt MetaCarta _______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
