You would think that adding youtube video’s to an infobubble using Google’s MyMaps would be easy. It turns out that unless you follow a series of undocumented steps, the youtube video will not embed successfully. Here are the steps needed in order to embed a video successfully into an infowindow.
- Go to the Youtube page that has the video you want to embed.
For example, check out this video of Randy Newman’s tour of Sunset Blvd. - Click on “Share” and then “Embed”
- Add “http:” to the “src=”//www.youtube.com/”parameter.
For example, using our Randy Newman video:
<iframe width=”420″ height=”315″ src=”//www.youtube.com/embed
/vNteJfogiDs” frameborder=”0″ allowfullscreen></iframe>
We need to change it to:
<iframe width=”420″ height=”315″ src=”http://www.youtube.com/embed/vNteJfogiDs” frameborder=”0″ allowfullscreen></iframe>