Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #474950

    I am looking to add background images to the Google maps tooltips, and thought this might be best done by adding class for each tooltip. How can I add a CSS Class to the tooltip.

    Alternatively if this isn’t possible, how else can I add a background image to a Google maps tooltip? Each one would need to be different for each Tooltip.

    #475020

    Hey Virtualentertainments!

    That is not handled by the theme and I don’t think the google maps api has any options for that so I don’t think that is going to be possible. You might be able to target the div containers with CSS if you go deep enough but I have not tested it out and it’s probably going to change for each map you create so it’s going to take a lot of work.

    Regards,
    Elliott

    • This reply was modified 8 years, 9 months ago by Elliott.
    #475064

    Ok Thanks, What if I put an image within the tooltip. Is there any way to override the width/height and padding etc? to match the size of my image

    #475392

    Hi!

    Even if you can add an image to the tooltip, you will not be able to style it correctly because there is no unique class. Unfortunately, there is no option to add a class attribute to the marker options: https://developers.google.com/maps/documentation/javascript/reference#MarkerOptions

    Cheers!
    Ismael

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.