Skip to content

Instantly share code, notes, and snippets.

@djrmom
Created November 28, 2018 12:56
Show Gist options
  • Save djrmom/4492a82bc9d23061e26bec010605e71c to your computer and use it in GitHub Desktop.
Save djrmom/4492a82bc9d23061e26bec010605e71c to your computer and use it in GitHub Desktop.
facetwp add lables to google map icons
<?php
/** add map facet icon labels **/
add_filter( 'facetwp_map_marker_args', function( $args, $post_id ) {
$args['label'] = esc_html( get_the_title( $post_id) );
return $args;
}, 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment