Events Made Easy › Forums › How do I … › Adding Map of all events to the template
Tagged: google maps, template code
- This topic has 11 replies, 4 voices, and was last updated 11 years, 10 months ago by Anonymous.
-
AuthorPosts
-
Tue 24 Apr 2012 at 20:21 #43794AnonymousInactive
So I see the shortcode to add a map to any content but I want to add one map that shows all event locations in my template page. I have found code to add the calendar and list as a template piece but nothing about the map. Slowly working my way into this. Great plugin!
Tue 24 Apr 2012 at 21:25 #49691FrankyKeymasterSee http://www.e-dynamics.be/wordpress/?cat=38 for the map shortcode. The corresponding function call for templates would be eme_global_map
Wed 25 Apr 2012 at 13:55 #49692AnonymousInactiveThanks for the reply.
http://76.12.196.238/~whiteriv/
So what am I missing there. It tells me I am missing an argument.
My code
<div><?php eme_global_map(); ?></div> <!—Here is the error–>
Wed 25 Apr 2012 at 15:05 #49693FrankyKeymasterTry changing the line 715 in eme_locations.php from
function eme_global_map($atts) {
to
function eme_global_map($atts=””) {
Wed 25 Apr 2012 at 20:59 #49694AnonymousInactiveIs this now a future bugfix?
(I didn’t even know global map was a feature!)
Wed 25 Apr 2012 at 21:02 #49695FrankyKeymasterWell … in fact any function that’s called for handling a shortcode can be called directly 🙂
In this case, I won’t change the code until jeynon confirms it works.
Tue 1 May 2012 at 14:53 #49696AnonymousInactiveI get nothing…
Tue 12 Feb 2013 at 21:43 #49697AnonymousInactiveHi,
I do use the [locations_map] shortcode, but as it is named, you get the map of locations, and not the map of events which is what I really want. In particular, you get a clickable “list of locations” and what I expect is a list of events.
Of course i could list the events in another way, using [events_list], but I would lose the link with the google map flag…
I would appreciate if you could help me.
Tue 12 Feb 2013 at 22:43 #49698FrankyKeymasterWell, I have something like this ready, but I’m still thinking about the best way to show it (the letters A,B,… correspond to the locations on the map):
A. Location 1
- event 1
- event 2
B. Location 2
- event 3
- event 4
...or:
A. event 1
A. event 2
B. event 3
...or:
- event 1 at location name 1
- event 2 at location name 1
- event 3 at location name 2
...In all cases the map will still show the location info like you specified it, not event info directly. For that, you can use the locations details, and use in there the code “[events_list location=this_location]” to show a list of events on that location (and all other usual options)
Edit: the first and the second layout are now possible in trunk
Wed 13 Feb 2013 at 21:06 #49699AnonymousInactiveHi Franky, thanks for your prompt reply.
I’m ok with your assumption that in all cases the map will show the location info, otherwise it would be difficult to manage several events in a same place.
Using the list of event in the detail section of the location is ok too.
The only problem remaining is the list. As you explained, selection of the best layout is not that easy, so I can understand you’re still thinking about it.
But what do you mean by “the first and second layout are now possible in trunk” ?
Wed 13 Feb 2013 at 21:20 #49700FrankyKeymasterThat means that in the current development version the first and second layout I suggested in my post above are now possible, and so it will be available in the next version.
Wed 13 Feb 2013 at 21:44 #49701AnonymousInactiveThat’s fine !
Thanks.
-
AuthorPosts
- The forum ‘How do I …’ is closed to new topics and replies.