CBX Map for Google Map & OpenStreetMap

Description

CBX Map for Google Map & OpenStreetMap makes it easy to add responsive maps to your WordPress website.

Choose between Google Maps and OpenStreetMap, create reusable map locations from the WordPress admin, or display a map directly with a simple shortcode.

The plugin is designed to keep map creation simple. You can search for a location, set the marker position, configure the map, and copy the shortcode with just a few clicks.

OpenStreetMap is supported as an alternative to Google Maps and can be used without a Google Maps API key.

CBX Map for Google Map & OpenStreetMap by Codeboxr

📺 Live Demo | 🌟 Upgrade to PRO | 📋 Documentation | 👨‍💻 Free Support | 🤴 Pro Support | 📱 Contact

Features

  • Google Maps support
  • OpenStreetMap support with no Google Maps API key required
  • Create and manage reusable maps from the WordPress admin
  • Custom post type for saved maps
  • Simple [cbxgooglemap] shortcode
  • Display maps without creating a custom map post
  • Responsive map layout
  • Automatic map resizing with the browser window
  • Configurable map zoom and map type
  • Marker and information window support
  • Custom information window title and content
  • Optional website link in the information window
  • Custom map marker icon
  • Global default settings
  • Map-specific settings through custom fields
  • Location search and easy marker positioning
  • Easy shortcode copying from the map editor
  • Gutenberg block support
  • Elementor widget support
  • Classic WordPress widget support
  • WPBakery Page Builder support

▶️ Watch the Video

Gutenberg, Elementor & Widget Support

CBX Map integrates with popular WordPress content-building tools.

  • Gutenberg Block — Add maps directly from the WordPress block editor.
  • Elementor — Add maps using an Elementor widget.
  • Classic Widget — Add maps through the traditional WordPress widget.
  • WPBakery Page Builder — Add maps using a WPBakery element.

Shortcode

The simplest way to display a saved map is:

[cbxgooglemap id="123"]

Replace 123 with the ID of a map created using the CBX Maps custom post type.

Display a Saved Map

Once you create a map from the WordPress admin, copy its shortcode and place it anywhere that supports WordPress shortcodes.

Example:

[cbxgooglemap id="123"]

Only the id attribute is required when displaying a saved map.

Display a Map Without a Saved Map

You can also create a map directly from shortcode attributes without creating a CBX Map custom post.

Example:

[cbxgooglemap lat="23.8103" lng="90.4125"]<h3>Shortcode Attributes</h3>

* id — Saved CBX Map post ID. Optional.
* maptype — Map type. Default: roadmap. Available values: roadmap, satellite, hybrid, terrain.
* width — Map width. Numeric values are treated as pixels. Percentage values such as 100% are also supported.
* height — Map height in pixels.
* zoom — Initial map zoom level. Default: 8.
* lat — Latitude of the map location. Required when using a map without a saved map post.
* lng — Longitude of the map location. Required when using a map without a saved map post.
* heading — Title displayed in the information window.
* website — Website URL linked from the place name in the information window. Leave empty to disable the link.
* address — Content displayed inside the information window.
* scrollwheel — Enable or disable mouse-wheel zooming. 1 = enabled, 0 = disabled.
* showinfo — Show or hide the information window. 1 = enabled, 0 = disabled.
* infow_open — Control whether the information window is initially open. 1 = open, 0 = closed.
* mapicon — Custom marker icon URL. Leave empty to use the default marker.

Example:

[cbxgooglemap lat="23.8103" lng="90.4125" zoom="12" maptype="roadmap" width="100%" height="400"]

For complete shortcode documentation and Pro features, see the CBX Map documentation.

CBX Map Pro

Get CBX Map Pro

Upgrade to CBX Map Pro to add advanced mapping and location features.

Pro Features

  • Distance search shortcode
  • Distance-based map and list display
  • Display multiple map locations on a single map
  • Use saved map posts as multiple markers
  • Make individual maps public or private
  • Map categories
  • Additional shortcode options and advanced functionality

▶️ Watch the Pro Video

For complete Pro documentation and shortcode options, visit the CBX Map documentation.

Automatic Installation

  1. From your WordPress dashboard, go to Plugins Add New.
  2. Search for CBX Map for Google Map & OpenStreetMap.
  3. Install the plugin.
  4. Activate the plugin.
  5. Go to the CBX Map settings and configure your preferred map provider.
  6. Create a map or use the [cbxgooglemap] shortcode to display a map.

Manual Installation

  1. Download the plugin.
  2. Upload the cbxgooglemap folder to /wp-content/plugins/.
  3. Activate the plugin from the Plugins menu in WordPress.
  4. Open the CBX Map settings.
  5. Configure your map provider and settings.
  6. Create a map or add the shortcode to your desired page, post, widget, or supported page builder.

Google Maps API

If you use Google Maps, configure the required Google Maps API credentials according to Google’s current API requirements.

If you use OpenStreetMap, a Google Maps API key is not required.

Support

Need help with CBX Map?

Screenshots

Blocks

This plugin provides 1 block.

  • Codeboxr Cbxgooglemap

FAQ

Does CBX Map support OpenStreetMap?

Yes. CBX Map supports both Google Maps and OpenStreetMap.

Do I need a Google Maps API key?

A Google Maps API key is required when using Google Maps, according to Google’s API requirements.

If you use OpenStreetMap, you do not need a Google Maps API key.

Can I display a map without creating a map from the admin?

Yes. You can display a map directly using shortcode attributes such as lat, lng, zoom, maptype, width, and height.

Can I create reusable maps?

Yes. CBX Map provides a custom post type that allows you to create and manage reusable map locations from the WordPress admin.

Is the map responsive?

Yes. Maps are designed to be responsive and adapt to the available browser width.

Does CBX Map support Gutenberg?

Yes. CBX Map provides a Gutenberg block for adding maps directly from the WordPress block editor.

Does CBX Map support Elementor?

Yes. CBX Map provides an Elementor widget.

Does CBX Map support WPBakery?

Yes. CBX Map provides WPBakery Page Builder support.

Is there a custom PHP function to display a map directly?

The recommended method for displaying maps is the [cbxgooglemap] shortcode or the available Gutenberg, Elementor, and widget integrations.

For advanced customization, please refer to the documentation or contact Codeboxr support.

Reviews

Kanama 11, 2022
Works with shortcode and the pro version can be used to add variables for integrating into custom posts with meta term geocoding fields. Great!
Mata 30, 2020 1 reply
One of the best and easy to use map plugin. Can use OpenStreetMap so you don’t need a paid licens from Gooogle. I was up and running in five minutes on my new website!
Mutarama 27, 2019
Thank good for this Plugin since getting a google API is a mess! I tried to get an API for two hours now. I give it up and will use openstreetmap and this plugin from now on. Thaaaaaaaank you!!!!
Read all 4 reviews

Contributors & Developers

“CBX Map for Google Map & OpenStreetMap” is open source software. The following people have contributed to this plugin.

Contributors

Changelog

2.0.5

  • [improvement] WordPress 7.1 compatibility.
  • [updated] Plugin Check 2.1.0 compatibility.
  • [updated] Pro addon 2.0.5 released.

2.0.4

  • [improvement] Improved JavaScript loading when the Google Maps API key is missing.
  • [updated] Plugin Check 1.8.0 compatibility.
  • [updated] Pro addon 2.0.4 released.
  • [updated] Miscellaneous improvements.

2.0.3

  • [improvement] Improved Pro and other plugin activation checks.
  • [improvement] Improved Pro addon deactivation notice.
  • [updated] Pro addon 2.0.3 released.
  • [updated] Miscellaneous improvements.