Quantcast
Channel: Web Development – Zack Katz's Blog
Viewing all articles
Browse latest Browse all 17

Set the Width for a Google Maps InfoWindow

$
0
0

Working with Google Maps v3 is way fun.

If you’re a masochist.

Infowindow width

Scrolling InfoWindow

It seems like there’s no easy way to set the width of an InfoWindow. You can set the minWidth parameter, but that does nothing.

If you have content that exceeds the InfoWindow window, you get this: a scrolling box. That’s terrible.

The solution is horribly easy.

Looking Through the InfoWindow

The solution presents itself.

This will solve all your problems, and make you wish you had the past two hours back of your life: use the provided .gm-style-iw class to style the InfoWindow content container.
/* Just use .gm-style-iw */
.gm-style-iw {
width: 300px;
min-height: 150px;
}

The post Set the Width for a Google Maps InfoWindow appeared first on Katz Web Services.


Viewing all articles
Browse latest Browse all 17

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>