1

The OpenLayers TransitionEffect='resize' property is not working while using GeoWebcache service of GeoServer

var demolayer = new OpenLayers.Layer.WMS(
    "Eg", "http://localhost:8080/geoserver/gwc/service/wms",
    {
             layers: 'Eg',
             format: 'image/gif' ,
             tiled: true,
             tilesorigin: [29.06213671874999, 28.912181118327]
            },
            {attribution: '©copy rights',
             tileSize: new OpenLayers.Size(256,256)},
            { transitionEffect: 'resize'
            }

          );
3
  • It would be helpful to show more code so we can check whether the property was placed in the correct place and try your code on our end. Also, your question is implied, but it helps to explicitly state your question.
    – CaptDragon
    Commented Jul 6, 2011 at 15:16
  • var layer = new OpenLayers.Layer.WMS( "Eg", "localhost:8080/geoserver/gwc/service/wms", { layers: 'Eg', format: 'image/gif' , // tiled: true}, {attribution: '©'}, {isBaseLayer :true, transitionEffect: 'resize'}, {tileSize: new OpenLayers.Size(256,256)} );
    – eng.M_mam
    Commented Jul 6, 2011 at 15:21
  • you can edit your original question.... to include code: paste in the code, highlight it, then press the "Code Sample" ({}) icon.
    – CaptDragon
    Commented Jul 6, 2011 at 15:22

1 Answer 1

6

You didn't include properties in the right place. Then again, you also didn't include working code, so perhaps this isn't your actual code, but the four args to WMS are:

  • name
  • URL
  • Properties (sent to server)
  • Options (used on the client)

So your code should look something like this:

var demolayer = new OpenLayers.Layer.WMS( "Eg", 
  "http://localhost:8080/geoserver/gwc/service/wms", 
  { layers: 'Eg', format: 'image/gif' , tiled: true, tilesorigin: [29.06213671874999, 28.912181118327] }, 
  {attribution: '©copy rights', transitionEffect: 'resize', tileSize: new OpenLayers.Size(256,256),//} );
2
  • 2
    @eng.M_mam: you can give him the credit by checking the check next to the answer to state that it was the correct answer :)
    – CaptDragon
    Commented Jul 6, 2011 at 16:41
  • @Christopher Schmidt : Working perfectly,Thanks a lot Commented Dec 9, 2014 at 5:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.