CSS scale height to match width - possibly with a formfactor

前端 未结 10 1742
天涯浪人
天涯浪人 2020-12-04 11:28

I have implemented a GoogleMapsV3 map in a twitterBootstrap basic responsive design site.

But my question is quite simple: i have:

10条回答
  •  温柔的废话
    2020-12-04 11:39

    I need to do "fluid" rectangles not squares.... so THANKS to JOPL .... didn't take but a minute....

    #map_container {
         position: relative;
         width: 100%;
         padding-bottom: 75%;
    }
    
    
    #map {
        position:absolute;
        width:100%;
        height:100%;
    }
    

提交回复
热议问题