• Resolved Pepepro

    (@pepepro)


    How can I display different icons on the mashup map based on the post category , or on custom fields?

    I tried this, but does not work:

    function prefix_pronamic_google_maps_marker_options_icon($url) {
    $tipo = get_post_meta(get_the_ID(), 'franquiciado', false);
    switch(get_post_meta(get_the_ID(), 'franquiciado', false)) {
    case 'post':
    $url = 'https://google-maps-icons.googlecode.com/files/seniorsite.png';
    break;
    case 'page':
    $url = 'https://google-maps-icons.googlecode.com/files/university.png';
    break;
    }
    return $url;
    }
    add_filter('pronamic_google_maps_marker_options_icon', 'prefix_pronamic_google_maps_marker_options_icon');

    thanks.

    https://www.ads-software.com/extend/plugins/pronamic-google-maps/

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Pronamic Google Maps] Different icons in mashup’ is closed to new replies.