How come my location map won't appear?
-
I’ve added the postcode into the required field, the map comes up and I click use. Nothing appears – what am I doing wrong?
The blog I need help with is: (visible only to logged in users)
-
HI again! :)
Since I don’t see that you’ve added any widgets for maps, I assume you’re talking about adding Locations to posts :
Different themes will handle that location data in different ways. Some of them may display the location prominently, and some not at all. Mostly I find it helps establish location-based relevance for search engine optimization.
If you’re wanting to display a map within the body of a page, post, or widget, I would recommend using a Google Map embed so you’re not reliant on your theme:
Best,
-Alex G.
-
Ah yes should have thought!
I’ve done it by embedding it as an iframe. Do you know how I can make the iframe a certain size? I’d like it to match the width of the contact fields above it. However, it ought to be scaleable too so its responsive.. can I have it all?!
-
.. can I have it all?!
Oh the frabjous things we could experience if so! :D
Most iframe embeds won’t work on WordPress.com for security reasons, but we’ve already made adjustments to our code to allow Google Maps.
If you’ll check out your post with a Google Map in it, you’ll see that WordPress has already transformed the HTML code to fit our embed needs:
The “w=600&h=450” controls the dimensions of the map. You can edit those dimensions to whatever you like. :)
Sadly, I cannot see a way to make the map responsive. By the nature of how we adjust the iframe embed for security, we cannot adjust the iframe attributes using CSS.
Best,
-Alex G.
-
..You must get bombarded with stuff being this helpful!!
I’ve successfully altered the map width for desktop and it seems the map fits to the window of my iPhone anyway.. Will it not fit other mobile screens like that then?
-
We do get a lot of support requests, but I just do my best to help and the time flies by!
I am seeing the same behavior! I’m not 100% sure why… but it’s definitely adjusting now where it hadn’t before.
Taking a closer look, my hypothesis is that with the original dimensions, the map was wider than the ‘div’ that was holding it. Once you adjusted the maps dimensions it became more subject to that div which shrinks responsively, so the map began to shrink responsively as well.
Good find! ;)
-Alex G.
-
- The topic ‘How come my location map won't appear?’ is closed to new replies.
