Title: Locations_Map
Last modified: December 7, 2018

---

# Locations_Map

 *  Resolved [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/)
 * Hi Patrick,
 * I already replaced Google Maps with OSM for the single events some weeks ago 
   on my own. Maybe your plugin could be interesting for me to also use it for the
   Locations and to get a proper display of the balloon-format. I couldn’t find 
   a solution for that on my own….
 * Therefore my questions are:
 * 1. Could your plugin also display a map with multiple markers as in [https://pferdetermine.de/deutschlandkarte](https://pferdetermine.de/deutschlandkarte)
   with the balloon-format from events-manager that you can also see when you click
   on one of the markers on that mentioned website?
 * I would like to get the address and the link to calculate the route (in Google
   Maps) and the upcoming events. The code in EM for that is the following:
 * [code]
    <strong>#_LOCATIONLINK</strong>&lt;p&gt;#_LOCATIONADDRESS&lt;/p&gt; #
   _LOCATIONPOSTCODE #_LOCATIONTOWN (<a href="[http://pferdetermine.de/veranstaltungen-fuer-pferd-und-reiter/pferde-veranstaltungen/pferdeveranstaltungen-#_LOCATIONSTATE">#_LOCATIONSTATE</a&gt](http://pferdetermine.de/veranstaltungen-fuer-pferd-und-reiter/pferde-veranstaltungen/pferdeveranstaltungen-#_LOCATIONSTATE">#_LOCATIONSTATE</a&gt);)&
   lt;/br&gt; <a href="[http://maps.google.com/maps?daddr=#_LOCATIONADDRESS%2C+#_LOCATIONTOWN%2C+#_LOCATIONSTATE%2C+#_LOCATIONPOSTCODE%2C+#_LOCATIONCOUNTRY&quot](http://maps.google.com/maps?daddr=#_LOCATIONADDRESS%2C+#_LOCATIONTOWN%2C+#_LOCATIONSTATE%2C+#_LOCATIONPOSTCODE%2C+#_LOCATIONCOUNTRY&quot);
   rel="nofollow" target="_blank">Route berechnen »</a> &lt;/br&gt; <strong>Kommende
   Veranstaltungen</strong> &lt;p&gt;#_LOCATIONNEXTEVENTS&lt;/p&gt; [/code]
 * 2. Does you plugin also replace the Google map in the create/edit-section for
   an event?
 * thanks for your support!
    Kathrin
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Flocations_map%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 15 replies - 1 through 15 (of 26 total)

1 [2](https://wordpress.org/support/topic/locations_map/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/locations_map/page/2/?output_format=md)

 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959022)
 * Hi Kathrin,
 * First of all, thanks for your interest in my plugin. 🙂
 * When I say “0% Google”, I do mean “0% Google”. LOL. So yes, it will also replace
   the admin map. There are still some quirks there, but I am currently trying to
   work them out. Hope for a new release later today or tomorrow.
 * The output is already in the EM format 🙂 That goes for single and multiple location
   maps.
 * If the code you gave is in Events → Settings → Formatting →Maps → Location Balloon
   format, then it should work.
 * You can safely try it out. If you do not edit anything (update, etc), all database
   info is untouched, but you can still see the output in the front-end events.
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959066)
 * My website is a live-website with more than 1000 events and several hundred users
   who can online create new locations and events. Therefore I cannot try it out
   without editing anything 😉
    And as far as I understand I need to have an API
   key for that (although it is free). So I will need some time and have to try 
   it once over night…
 * I assume that I could change back to my existing config even if I edited locations
   with your plugin in case it wouldn’t work?
 * Btw: can I test it on a localhost test-site? Google Maps does not work there.
   Would your plugin work on a localhost?
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959130)
 * Just installed it on my localhost.
    For single events there is no marker shown
   and the locations_maps only shows my local area and also no marker at all…. ([
   locations_map width=100% height=800 scope=”future” em_locations_get_default_search
   =1 eventful=1][/locations_map]) So where is the trick? What do I have to change
   where so that it works?
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959150)
 * Please see the FAQ’s… width 100% is the problem. It thinks on load that 100% 
   is full screen, so the markers and map are centered on that. If you add a max-
   width it will be solved.
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959154)
 * You have not read the description 🙁
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10959218)
 * I read the description 😉 In the single event there is no width=100% and in the
   settings I added instead of my formerly 520px :
    100%; max-width:520px !important;
   min-width:350px just as it was stated in your FAQ. But I do not see any marker
   on my localhost with that setting. and the singleevent now just uses #_LOCATIONMAP…
   Any idea what might be missing?
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10963548)
 * Patrick, any idea, why I do not see any marker in the map? In the admin-area 
   when editing a location, I can see a marker. But not when using the normal shortcodes
   in the events/locations….
    I already use the API now (that one works) and have
   nothing in use on my local test-site but the pure Shortcode…. but no marker in
   the map…. 🙁
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10963621)
 * No, you should have one, but without a link it’s hard to tell.
    -  This reply was modified 7 years, 4 months ago by [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/).
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10969917)
 * Please update to version 1.4. 🙂
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10974460)
 * Just updated to the latest version 1.5 on my localhost
    Now I see no map at all!
   🙁 Neither in the single events nor the locations nor he locations_map…
 * The Google Chrome Console says: Uncaught SyntaxError: Invalid or unexpected token
   in line …
 *     ```
       const balloon = '<strong><a href=\"http://localhost/wordpress_pferd/veranstaltungsort/pferdepension-spitzbarth/\">Pferdepension Spitzbarth</a></strong>
   
       I guess it is related to one of the lines before:
       		<link rel="stylesheet" href="http://localhost/wordpress_pferd/wp-content/plugins/stonehenge-em-osm/inc/em-osm.min.css">
       		<script src="http://localhost/wordpress_pferd/wp-content/plugins/stonehenge-em-osm/inc/em-osm.min.js"></script>
       ```
   
 * It is probably the http:// before the localhost that does not work…
 * I will only be able to use or test your plugin on the live website when your 
   plugin supports the full shortcode functionality of EM for example shortcodes
   like
    `[locations_map eventful=1 scope="future" near="#_LOCATIONLATITUDE,#_LOCATIONLONGITUDE"
   near_unit="km" near_distance="100"]` or `[locations_map eventful="1" scope="future"
   state="Schleswig-Holstein"]` AND when it shows Map, Marker and all Balloons correctly.
   My website is probably one of the more complex and bigger EM-Installations with
   a very extensive use of the Google Map (that I already partially migrated to 
   OSM, because otherwise I would have had tremendous costs already.
 * If you need anything further from the google chrome console to analyze this, 
   just let me know. I would love to migrate everything to OSM.
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10974829)
 * Things for me to look into 🙂
    The balloon should work. I get no errors, both
   on my live blogs and on my localhost. If I copy/paste your const balloon value,
   it works. What happens if you change the balloon content in the EM settings?
 * The near=”#_LOCATIONLATITUDE,#_LOCATIONLONGITUDE” in your shortcode will only
   work if you use the shortcode in an already existing EM_Locations Object, for
   example a location page. There is no location ID provided in the shortcode, so
   using #_LOCATIONLATITUDE will then return 0.
 * The fasted way for you to test if you get the error because of minified scripts,
   is by altering the code, just a little.
 * In the function construct_multiple_map($args) (starts around line 460, replace
 *     ```
       <link rel="stylesheet" href="<?php echo plugins_url('inc/em-osm.min.css', __FILE__ ); ?>">
       <script src="<?php echo plugins_url('inc/em-osm.min.js', __FILE__ ); ?>"></script>
       ```
   
 * With the separate, un-minified scripts:
 *     ```
       <link rel="stylesheet" href="<?php echo plugins_url('inc/leaflet.css', __FILE__ ); ?>">
       <link rel="stylesheet" href="<?php echo plugins_url('inc/fullscreen.css', __FILE__ ); ?>">
       <script src="<?php echo plugins_url('inc/leaflet.js', __FILE__ ); ?>"></script>
       <script src="<?php echo plugins_url('inc/esri-leaflet.js', __FILE__); ?>"></script>
       <script src="<?php echo plugins_url('inc/fullscreen.js', __FILE__); ?>"></script> 
       ```
   
 * Please let me know the outcome of that. 🙂
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10974852)
 * Is “**[Pferdepension Spitzbarth](http://localhost/wordpress_pferd/veranstaltungsort/pferdepension-spitzbarth/)**”
   the complete content of your Ballon markup in Events → Formatting → Maps?
 * I think you have a hard enter in there. That breaks the code! Please make sure
   there are no hard enters (new lines) in the ballon content.
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10974957)
 * Version 1.5.1 should solve the hard enter in your ballon text. It replaces hard
   enters with a break tag.
 *  Thread Starter [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * (@pferdetermine)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10981295)
 * Hi Patrick, I disabled all minifying etc. But that does not change a thing. The
   main problem on my test-website is that all links include the **http:// **before
   the **localhost** – which is wrong. **I do not see any map at all**! And this
   is not related to the minify or the balloon markup.
 *  Plugin Author [Stonehenge Creations](https://wordpress.org/support/users/duisterdenhaag/)
 * (@duisterdenhaag)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/locations_map/#post-10981311)
 * http:// is not wrong, because that is always with a localhost. Mine as well. 
   That is not the problem. And that is added automatically, because the source 
   is //, meaning the protocol is added depending on your server configuration.
 * Did you download version 1.5.1. There are changes already.
 * Any errors in your console?

Viewing 15 replies - 1 through 15 (of 26 total)

1 [2](https://wordpress.org/support/topic/locations_map/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/locations_map/page/2/?output_format=md)

The topic ‘Locations_Map’ is closed to new replies.

 * ![](https://ps.w.org/stonehenge-em-osm/assets/icon-256x256.jpg?rev=2143406)
 * [Events Manager - OpenStreetMaps](https://wordpress.org/plugins/stonehenge-em-osm/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/stonehenge-em-osm/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/stonehenge-em-osm/)
 * [Active Topics](https://wordpress.org/support/plugin/stonehenge-em-osm/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/stonehenge-em-osm/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/stonehenge-em-osm/reviews/)

## Tags

 * [balloon](https://wordpress.org/support/topic-tag/balloon/)
 * [Locations_map](https://wordpress.org/support/topic-tag/locations_map/)

 * 26 replies
 * 2 participants
 * Last reply from: [pferdetermine](https://wordpress.org/support/users/pferdetermine/)
 * Last activity: [7 years, 3 months ago](https://wordpress.org/support/topic/locations_map/page/2/#post-10986407)
 * Status: resolved