Support » Plugin: Events Manager » [Plugin: Events Manager] location address missing for google calendar and ical

Viewing 11 replies - 1 through 11 (of 11 total)
  • you can modify that using template file at templates/ical.php or ical-event.php

    Using Template Files

    Hm, well it’s going to take me some amount of time to muck around in there. Meanwhile, wouldn’t you agree that a location without an address is a problem, not a feature?

    I figured out how to correct the problem for the generated ics file in i-cal-event.php. But I do not see where to correct it for the parameters passed in the url to google. Please advise.

    can you share the solution?

    in ical-event.php, line 33

    $location = $EM_Event->output( '#_LOCATION' );

    after (using a local template, of course):

    That gives me all the info for the ics file. But which function/file is passing the parameters to the google url? That is the one I need to change.

    it’s the area here:


    No, that info is what goes into the ics file. It does not have any effect on the url parameters passed to google. BUT I found it:

    In em-event.php, line 1457:

    $gcal_url = str_replace('location_name', urlencode($this->output('#_LOCATION')), $gcal_url);

    $gcal_url = str_replace('location_name', urlencode($this->output('#_LOCATION #_LOCATIONADDRESS #_LOCATIONTOWN #_LOCATIONSTATE #_LOCATIONPOSTCODE')), $gcal_url);

    Now google calendar can generate a map for the location. Would you consider this for an update? I don’t know if there is any way to hook into your code, so I had to hack it.

    you can try to modify/override placeholder instead to make it update free

    Plugin Author Marcus


    rather than do that, I’d make this an option in the settings page, so you can change placeholders there.

    Please explain further. Are you suggesting an update that you would make to the plugin?

    I wonder why #_LOCATION and #_LOCATIONNAME are both the same thing. It would make sense to me to have #_LOCATION be the combination of #_LOCATIONNAME #_LOCATIONADDRESS #_LOCATIONTOWN #_LOCATIONSTATE and #_LOCATIONPOSTCODE.

    BUT… since it is not, I am trying to modify the #_LOCATION placeholder. AND I need help. Using your example:

    function my_em_placeholder_mod($replace, $EM_Location, $result){
    	if ( $result == '#_LOCATION' ) {
    		$replace = $replace . WHAT GOES HERE?;
    	return $replace;

    What do I put where it says WHAT GOES HERE? I tried, for example, ‘#_LOCATIONPOSTCODE’ and #_LOCATIONPOSTCODE but neither of those worked.

    Allrighty I think I got it. Let me know if you see any fatal flaws:

    function my_em_placeholder_mod( $replace, $EM_Location, $result ){
    	if ( $result == '#_LOCATION' ) {
    	return $replace;
    add_filter( 'em_location_output_placeholder','my_em_placeholder_mod',1,3 );

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘[Plugin: Events Manager] location address missing for google calendar and ical’ is closed to new replies.