Legacy (OIder) Layout (v9)
...
Map Features
Markers

Embedding iframes in your markers

6min

Overview

WP Go Maps Basic version 8.1.13 and above strip away any tags that are considered to be unsafe.

‘wp_kses_post’ considers iframes to be ‘unsafe’ and thus are stripped away. This article will show you how to embed an iframe in WP Go Maps (specifically focuses on the marker descriptions) using the iframe plugin.

Prerequisites

The Following Plugin/s need to be installed and active in order to embed iframes into your marker descriptions

Install and activate the ‘iframe’ plugin

Navigate to

WordPress Dashboard -> Plugins -> Add New

In the Search box at the top-right of the screen, type the word “iframe” and press {Enter}.

Click the Install Now button shown in the screenshot below. The plugin will install without any intervention.

Install iframe
Install iframe


Once installed, click the Activate button shown in the screenshot below. The plugin will then activate.

Activating the iframe plugin
Activating the iframe plugin


Add the Shortcode to the marker description

Navigate to your Map Editor to add or edit a marker

WP Go MAPS -> Maps (edit your chosen map) -> Markers

Add your iframe to your marker description in the respective shortcode format: [iframe src=”url” title=”description“]

E.g.

[iframe width="560" height="315" src="https://www.youtube.com/embed/D1vYTAM_53k" title="Importing Markers in New York" frameborder-"0" allowfullscreen]

When using the iframe plugin to embed Youtube videos, kindly ensure you are using Youtube's embed URL in your shortcode and also ensure the the https protocol is specified in the URL (not http). The embed URL can be retrieved by viewing the video on Youtube.com, selecting "Share" and copying the url from the embed option

Selecting the Youtube embed URL
Selecting the Youtube embed URL




Add iframe to marker description using the shortcode
Add iframe to marker description using the shortcode


Save your marker and the iframe should then be displayed in your marker.

iframe example
iframe example