Filter by country – Link user data with posts (as taxonomy?)

Home Forums Cera – Intranet & Community Theme Popular Features Member Profile Search Filter by country – Link user data with posts (as taxonomy?)

This topic contains 5 replies, has 2 voices, and was last updated by  Olivier 1 month, 2 weeks ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #13356

    Pilgrim Creative Team
    Participant
    • 40 Posts
    @pilgrimteam

    Hello again,

    This is a complicated question so I’ll do my best to explain as clearly as possible πŸ˜‰

    We are building a blog with many authors (150+) that come from many different countries.
    So far I have added a custom profile field, a dropdown where I have manually entered all countries (tedious task).
    We’re trying to have the articles written by each author “linked” automatically to the author’s country. So that if we search for “France” for instance, the search query could return all the articles that have been written by French authors.
    I’ve thought about using something like Pods to create a new taxonomy, but I just don’t know how to do it.

    Do you think there is a way to achieve this? Maybe some kind of workaround?

    Thank you for your answer!

    The Pilgrim team

    #13409

    Olivier
    Moderator
    • 1750 Posts
    @themosaurusrex
    Themosaurus Support

    Hi @pilgrimteam,

    You could consider adding a Location field and using Google Maps autocompletion by installing and activating BP xProfile Location:

    BP xProfile Location

    It is a very powerful plugin that integrates well with our theme. You could consider going even further and buying BP Maps for Members, to locate users on a map. It’s not fully supported by Cera but it is with its sister project Gwangi which share the same core (Grimlock and Grimlock for BuddyPress):
    https://dating.gwangi-theme.com/members/membersmap/

    If you end up running into issue, those should be minor.

    Best,

    #13420

    Pilgrim Creative Team
    Participant
    • 40 Posts
    @pilgrimteam

    Hey Olivier, thank you for your answer!

    We have tried using and setting up xProfile Location but we had several issues.
    Mainly we couldn’t find a way to select/show only the country and not the whole address. For privacy reasons we wouldn’t want those details to be displayed on the user’s profile.

    We searched through their support forum, and found this: xProfile Location Support Forum

    There is a filter you can use to adjust the displayed profile value.
    apply_filters('pp_loc_show_field_value', $value, $type, $id);
    It is in this file:
    bp-xprofile-location\inc\pp-field-type-location.php

    We haven’t found a way to add this filter though (we unfortunately don’t have FTP access for this project, and also coding skills are limited).
    But maybe it is a lead? Perhaps something that could be included in an new version of the theme? Anyway, it all seemed like too much trouble for me, so I opted to keep the dropdown for now (since it’s there already…)

    BUT what I still don’t really understand is how to connect content to authors, posts to members. That’s the tricky part I guess, how to use member data to filter/search posts? Maybe it simply isn’t feasible πŸ€·πŸΌβ€β™€οΈ?

    Thanks for your input on this!

    Have a good afternoon,

    #13482

    Olivier
    Moderator
    • 1750 Posts
    @themosaurusrex
    Themosaurus Support

    @pilgrimteam Oh, that’s a bummer. I’m sorry about that… I was convinced that bundling BP Maps for Members and BP xProfile Location would have been the right fit for you. πŸ˜”

    Thank you for your suggesting, we might consider adding this option to our theme. I’ll discuss this with our dev team as I share you view on this point.

    OK, I would try to:
    – Install Social Articles
    – Create post tags or categories in WP admin for each country
    – Add a the tag/category to the posts
    – Install BuddyPress Xprofile Custom Field Types (https://wordpress.org/plugins/bp-xprofile-custom-field-types/)
    – Create an extra profile field to match my members with my taxonomies (post tag or category)

    Ans you’re all set! This will show the tags/categories on the member cards. Each member will be able to select its own and clicking these links from their profile will open a page with all articles related with the category. (Please see attached.)
    Maybe you can go further and create a new custom taxonomy (“Country”) to apply to your posts if you don’t want to mess with existing tags and categories but I’m sure this will already get the job done for you.

    I know this is pretty advanced stuff by what you’re describing is not easy to achieve without any custom development. I hope this setup will do the trick for you. πŸ™‚

    #13588

    Pilgrim Creative Team
    Participant
    • 40 Posts
    @pilgrimteam

    Hey Olivier!
    Thanks for the suggestion, that’s exactly what I think I’ll do. I think creating the custom category with Pods or make it easier with a plugin like WP GeoNames.

    Thanks for the help!

    #13965

    Olivier
    Moderator
    • 1750 Posts
    @themosaurusrex
    Themosaurus Support

    You’re welcome! Thank you also to share this plugin with the rest of us! It might help others looking for the same feature.

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

The topic ‘Filter by country – Link user data with posts (as taxonomy?)’ is closed to new replies.