

In addition, in the script you have access to the following variables: In the script, you can use any JS code, such as: execute standard or custom functions, read and write values of variables, parse the HTML document and whatever else. However, if you have multiple instances of the map on the same page, each one will execute its own custom JS code. Any further redraws of the map do not trigger the execution. How custom JavaScript worksĬustom JavaScript code is executed when the map is drawn for the first time.
Click map javascript update#
The following update refers to the following products: US Map for WP, World countries Map for WP, as well as all single-level map plugins. And now this gets even simpler thanks to the custom JavaScript code field already added into the plugin settings. In this post you can find some examples of map interaction that even a complete rookie can implement.Īt the same time, our maps have JavaScript API, so experienced developers can implement complex and non-standard usage scenarios for plugins. Settings cover colors, tooltips, adding points, grouping countries into regions, and other possibilities.

All settings are visual and do not require any coding. Our plugins are well-acclaimed for their extremely simple interface, so even a novice WordPress user can easily configure and embed an interactive map on his or her WordPress website. Enhancing capabilities of Map plugins for WordPress Thanks to this feature you can implement all kinds of interactive behavior previously impossible or hard to do. This code executes after the map is drawn and has access to most of the map’s properties. Now you can add custom JavaScript code to the map. Empowerment with Custom JS 3 examples of how you can enhance the functionality of the interactive map for WordPress.Īs of version 2.9.9.6, our WordPress map plugins support a new advanced feature.
