How to change map size and location on page?

Hi there,

I'm using the plugin with Buddypress, page link here:

How do I (1) move the map just above where it says "Our Members" and (2) make the map span the width of the content?

Also, would it be possible to (3) have a separate site page/display of the map taking up the entire body section of the site while keeping the header? (On a separate page) - I'll upload a screenshot below.

  • Timothy
    • Chief Pigeon

    Hey there.

    You can set the default sizes in:

    Admin --> Settings --> Google Maps


    You can also add custom CSS in there.

    To target before the members loop you have:

    do_action( 'bp_before_members_loop' );

    You could also create your own I suppose and then you will know for sure it goes to the right place.

    You can checkout and see the code for members list in the following file:


    Studying that file should let you see how the plugin currently adds the map.

    Take care.

  • davejmason
    • Site Builder, Child of Zeus

    Ah great, I didn't realise that size option handled the map in the member area. That's that sorted. Thanks.

    As for moving the map on the page. I can see this code in agm-bp-profile_maps.php :

    function create_show_in_members_list_box () {
    		$show_in_members_list = $this->_get_options('show_in_members_list');
    		$values = array(
    			'' => __('Do not show in members list', 'agm_google_maps'),
    			'before' => __('Show map before members list', 'agm_google_maps'),
    			'after' => __('Show map after members list', 'agm_google_maps'),
    		foreach ($values as $key=>$val) {
    			$checked = ($show_in_members_list == $key) ? 'checked="checked"' : '';
    			echo '' .
    				"<input type='radio' name='agm_google_maps[bp_profile_maps-show_in_members_list]' value='{$key}' 
    id='agm-bp_profile_maps-show_in_members_list-{$key}' {$checked} /> " .
    				"<label for='agm-bp_profile_maps-show_in_members_list-{$key}'>{$val}</label>" .
    			'<br />';

    I'm not sure how to manipulate it to make it show *before* the member list though? I see this:

    'before' => __('Show map before members list', 'agm_google_maps'),

    but I'm lost as to what all this code means and what to do with it. Any ideas?



  • davejmason
    • Site Builder, Child of Zeus

    Actually, scrap that idea. I'm going to stick with the idea of one big map filling up the body of the page. I guess I'm going to have to study the same file and work out how to remove the footer etc. I'll post back when I have a more specific question. :slight_smile:

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.