Skip to content

Shortcode basics ​

WP Google Street View provides two shortcode modes to fit different use cases.

Mode 1: [wpgsv] — The CPT shortcode ​

This is the primary shortcode. It references a map entry created in the WP Google Street View custom post type.

[wpgsv id="42"]

The id parameter is the post ID of your WPGSV map entry. All configuration (address, type, style, markers, etc.) comes from the saved post.

When to use it: When you need full control over the map configuration through the admin interface, or when you want to reuse the same map on multiple pages.

Mode 2: [wpgsv_map] — The inline shortcode ​

This shortcode does not require a saved post. You pass the coordinates and options directly as attributes.

[wpgsv_map lat="48.8566" lng="2.3522" type="street" zoom="14" width="100%" height="450px"]

Available parameters ​

ParameterDefaultDescription
lat(required)Latitude
lng(required)Longitude
typestreetMap type: street, map, or streetmap (Pro)
zoom10Zoom level (1–20)
width100%Container width (CSS value)
height450pxContainer height (CSS value)
info(empty)Text content for the info box

Examples ​

Street View of the Eiffel Tower:

[wpgsv_map lat="48.8584" lng="2.2945" type="street" zoom="1"]

Google Maps of Times Square:

[wpgsv_map lat="40.7580" lng="-73.9855" type="map" zoom="15" info="Times Square, NYC"]

Synchronized view (Pro):

[wpgsv_map lat="40.7580" lng="-73.9855" type="streetmap" zoom="14"]

Multiple maps on one page ​

Both shortcode modes support multiple instances on the same page. Each map renders independently. There is no limit to the number of maps per page, though more maps means more Google Maps API calls.

Next steps ​

Try Pro free for 7 days

All features unlocked. Cancel anytime.

Start free trial

A WordPress plugin by PAGUP