Skip to content

Instantly share code, notes, and snippets.

@wpflippercode
Created September 8, 2017 06:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wpflippercode/8f7700f850a891cfc4c491fc3e568aed to your computer and use it in GitHub Desktop.
Save wpflippercode/8f7700f850a891cfc4c491fc3e568aed to your computer and use it in GitHub Desktop.
Modify Info Window Message Page Wise.
add_filter('wpgmp_infowindow_message', 'wpgmp_infowindow_message',1,2 );
function wpgmp_infowindow_message($message,$map) {
global $post;
if( $post->ID == 1) {
$message = "<h1>{marker_title}</h1>";
}
if( $post->ID == 2) {
$message = "<h1>{marker_title}</h1><p>{marker_address}</p>";
}
return $message;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment