1. Home
  2. Knowledge Base
  3. Customization
  4. Change or extend content of each location bubble

Change or extend content of each location bubble

You can use the Hook oum_locations_bubble_content to manipulate the content of the info bubbles of locations.

Insert the following PHP code in the functions.php of your theme:

add_filter('oum_location_bubble_content', function ( $content, $location ) {

    // extend or change content

    $content .= 'Post ID: ' . $location['post_id'];

    return $content;

}, 10, 2);

To add a value from default fields edit this line :

$content .= $location['post_id']; // use post_id, date, name, address, lat, lng, text, image, audio

And to add a value from a custom field:

$content .= oum_get_location_value('CUSTOM FIELD LABEL', $location['post_id']);

Change CUSTOM FIELD LABEL to the name of your custom field.

Was this article helpful?

Related Articles

Need Support?

Can't find the answer you're looking for?
Contact Support

EN