Teja Maridu
Teja Maridu

Reputation: 545

Set openlayers map height 100%

In openlayers when am trying to set map height: 100%; the map itself not displaying. When setting height: 800px; like this its showing white space in some resolution and scroller in some resolution. So i want to do it like it can adjust height automatically. But height: 100%; not helping.

<div id="map" style="height: 100%; width:100%; float:left; position: absolute;"> 
</div>

How do i solve this issue?

Upvotes: 3

Views: 6015

Answers (1)

Teja Maridu
Teja Maridu

Reputation: 545

This is a simple solution.

<div id="map" style="width: 100%; height: 100%; position:fixed">
</div>

Upvotes: 2

Related Questions