Hi Bob,

There is the Refresh strategy (OpenLayers.Strategy.Refresh) which works for WFS 
layers, don't know if it also works on MapServer or WMS layers though

Cheers Kris

Met vriendelijke groet, Kind regards,

Kristiaan Geusebroek
Consultant


[cid:[email protected]][cid:[email protected]]



Email: [email protected]<mailto:[email protected]>
Tel: +31 (0)35 538 1921
Fax: +31 (0)35 538 1922
Mobiel: +31 (0)6 3069 7223

Utrechtseweg 49
1213 TL Hilversum
The Netherlands
http://www.xebia.com<http://www.xebia.com/>

Xebia Blog: http://blog.xebia.com/


On Mar 27, 2012, at 12:21 AM, Bob Basques wrote:

In case anyone wants to take a deeper look . . . .  
http://pwultra5.ci.stpaul.mn.us/cp_tiles/OpenLayers/OL.AVL.09-rlb.html





>>> "Bob Basques" 
>>> <[email protected]<mailto:[email protected]>> wrote:
I have tried this (last).  I can't get it to reload anything.  I tried a few 
different approaches, Help!! NOTE: Map displays fine on load, just won't 
refresh automatically at any interval.  Thanks :

var mslayer6 = new OpenLayers.Layer.MapServer( "<br /><img 
src=\"http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_public.map?mode=legend\";>",
            
"http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_public.map?";,
             {layers: '',
              format: "image/png",
              transparent: "true"},

             {singleTile: "true",
              transitionEffect: 'resize',
              ratio: 1,
                  displayInLayerSwitcher:'false'}
      );

function init() {

. . . some  other stuff . . .

        window.setInterval(refreshData, 5000, mslayer6);

} // END init

        function refreshData(layer){
            //setting loaded to false unloads the layer//
            layer.loaded = true;
            //setting visibility to true forces a reload of the layer//
            layer.setVisibility(true);
            //the refresh will force it to get the new KML data//
            
layer.setUrl('http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_public.map?');
        }

_______________________________________________
Users mailing list
[email protected]<mailto:[email protected]>
http://lists.osgeo.org/mailman/listinfo/openlayers-users

<<inline: image005.jpg>>

<<inline: image006.png>>

_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to