Forum: Kleo Geolocation

This forum is closed for new topics. However, you can still search for a solution in the old topics. For technical support related to the Kleo Geolocation premium extension please open a new premium support ticket.

[Resolved]Hide address in BuddyPress profile

Home Forums Kleo Geolocation Hide address in BuddyPress profile

Tagged: ,

This topic contains 7 replies, has 2 voices, and was last updated by  Eyal Fitoussi 3 years, 4 months ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #53487

    dlx
    Participant

    I would like having a little more privacy for the users and not display their complete address (street / no / zip / city / country) in BuddyPress. I think displaying city + country should be fine.

    Already tried adding the code shown in this post: https://geomywp.com/forums/topic/hide-full-adress/ but this didn´t work.

    Is there any other filter to change the display of the address below the map in the user´s profile (screenshot attached)?

    Attachments:
    You must be logged in to view attached files.
    #53489

    Eyal Fitoussi
    Keymaster

    HI Dix,
    The filter you are looking for is:

    It can be found in the file
    geo-my-wp/plugins/friends/includes/gmw-fl-component.php in line 157.

    If you look in the script you will see that the filter can modify the [gmw_single_location] which displays the map and address.

    You need to modify the “address_fields” shortcode a using the filter to pass address_fields=”city,country” instead of address_fields=”address”.

    I hope that helps.

    #53496

    dlx
    Participant

    Hi Eyal!

    Found the filter in gmw-fl-component.php but don´t know how to add this to my functions.php.
    I tried the following code:

    Unfortunately this didn´t change anything.

    #53521

    Eyal Fitoussi
    Keymaster

    Do you have the Single Location core add-on activated?

    #53532

    dlx
    Participant

    No, the Single Location core add-on is not activated.
    Should I activated it to get more options?

    To be noticed: I´m not sure if the code I provided is correct. I´m not a PHP pro… 😉

    #53533

    Eyal Fitoussi
    Keymaster

    Hi,
    Yes, you should activate the ads-on as It has more features and better for performance. Also, the built in feature will be removed In the next update of the plugin so activating the add-on will be a must in order to use its features.

    And the script above looks fine. But you will know if it works only after the activation of the add-on.

    #53534

    dlx
    Participant

    Wow, yes! Looks great! Thanks a lot!

    #53580

    Eyal Fitoussi
    Keymaster

    You are very welcome!

Viewing 8 posts - 1 through 8 (of 8 total)

The topic ‘Hide address in BuddyPress profile’ is closed to new replies.