How to limit vertically the extent of an OpenLayers map?

المشرف العام

Administrator
طاقم الإدارة
When I pan north, the map goes out and I see the white background of my HTML. I want to pan vertically and the map to block when it reaches the top (or bottom, respectively).

I have tried to put bounds, but this solution puts also bounds horizontally. I want to be able to pan infinitely left or right, but limit the panning up and down.

How could I do this?

Thanks





أكثر...
 
أعلى