Support only during business hours : Monday to friday, from 8:30 am – 5:30 pm CEST

Due to the decrease in our staff due to vacations, our response time may be longer.

Be sure we're doing our best to manage your topic as soon as possible.

Disconnect between Map and Members

This topic is resolved
Viewing 21 posts - 1 through 21 (of 21 total)
  • Author
    Posts
  • René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Hi,

    There seems to be a disconnect between our members Map and the Members on the page.
    We use pagination, per 24, and even on the first page, the 24 members shown on the Map
    are not the same as shown on the first page:

    https://dating.wappiez.nl/leden/membersmap/

    It does show only 24 though, does there is some connection, but just not a good one.
    Any idea on how to fix this?

    Thx

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    Unfortunately, we have no clue. 🤷🏻‍♀️

    As this issue is related with the BP Maps for Members, it’s best if you try to reach the plugin authors. They will be more informed and better suited to help you.

    To go further, we invite you to post your request on their support forums:
    https://www.philopress.com/support/

    Don’t hesitate to share the solution with us. I’m sure it will help other users facing the same issue. By doing this, you will be making a great contribution to this forum, and we thank you very much for that! #SharingIsCaring 💪🏻

    Best,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Kay, so I had contact and my devs had a second look at it. Looks like the problem is exactly the opposite. Because there is a connection between the pagination and BP Maps for members, BP Maps is not shown correctly. BP Maps will only show all members. Now it only shows 24 random members. So, the solution would be to create a disconnect between the pagination and the BP Maps for Members plugin. Do you know how?

    Also, my devs told me this was because it was created on the Customizer that the pagination was hard coded into the theme. I’m not sure we did this or it was like this from the start, but maybe you could help me out with a nice snippet? Pleaseeee. 🙂

    Thx

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René, 🙂

    Thank you for bringing this to our attention. We will investigate further to find out how we can help you.

    We will be back to you ASAP.

    Thank you for your patience.

    Regards,

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    Thank you for your feedback.

    I suggest you to increase the number of members to display. You should be able to change that option in Customizer > BuddyPress > Members Directory. Please find the attached screenshot.

    Changing this should solve your issue.

    Best,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Well yeah, we know this, but then we’ll have to put in 0. Do you know how slow the page will get when we need to load all the members? I feel a limit is always necessary.

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Maybe it’s possible to have the Map on a single page and the search form on a single page?

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Could you tell me if the form on the members directory was created with BuddyBoss Profile Search or the BP Profile Search plugin?

    I’m thinking of creating a disconnect by duplicating the Members Directory page limit in Customizer and put one on the Map page and one on the Search form page. You think this is possible?

    I will still need to create a disconnect though and for this need to contact the authors of the Search form to hopefully change the shortcode.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    To change this, simply add the following code snippet to your website:

    /**
    * Disconnect the limit of members displayed in the map page
    */
    add_action( 'bp_before_members_page_map', function() {
    	add_filter( 'grimlock_buddypress_members_per_page', function( $per_page ) {
    		return 0;
    	}, 999 );
    
    	add_filter( 'bp_ajax_querystring', function ( $query_string, $object ) {
    		if ( ! is_string( $query_string ) || 'members' !== $object ) {
    			return $query_string;
    		}
    
    		$query_args = explode( '&', $query_string );
    
    		foreach ( $query_args as $key => $query_arg ) {
    			if ( strpos( $query_arg, 'per_page' ) !== false ) {
    				unset( $query_args[ $key ] );
    				break;
    			}
    		}
    
    		$query_args[] = 'per_page=0';
    
    		$query_string = implode( '&', $query_args );
    
    		return $query_string;
    	}, 999, 2 );
    } );

    To add this code snippet to your site, we recommend that you use the Code Snippets plugin (https://wordpress.org/plugins/code-snippets/). If you have never activated this plugin, please read the following post: Adding Custom PHP Without Changing Your Child Theme.

    Please also note that we don’t provide any theme customization. So, you shouldn’t expect other snippets from us unless it’s to fix an issue stemming from our own codebase. We always try our best to help theme users whenever we can and only provide code snippets out of courtesy to prevent them from waiting for the next update.

    Hope this will suits your needs. 🙂

    Regards,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Thank you.

    I’m getting a 500 error however when I activate it.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    Please be aware that we just updated the snippet in my previous answer.

    However, we believe your 500 error is related to the latest version of the BP Maps for Members plugin. We will be releasing an update of Grimlock for BuddyPress plugin very soon which should resolve your issue.

    I will be back to you as soon as this update is available! 🙂

    Best,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    I’m not sure that this is because of the new BP Maps for Members update, because we also have a staging environment and I was unable to update to the newest BP Maps for Members update there because I was unauthorized. And I’m still getting a 500 error. Do you want me to give you access to our staging site as well?

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Thank you for your feedback.

    To help us getting clues and find a solution to this issue, please activate logging on your website, just turn WP_DEBUG to true, by pasting the following code lines in your wp-config.php file, just before the line that says ‘That’s all, stop editing! Happy blogging.’:

    // Enable WP_DEBUG mode
    define( 'WP_DEBUG', true );
    
    // Enable Debug logging to the /wp-content/debug.log file
    define( 'WP_DEBUG_LOG', true );
    
    // Disable display of errors and warnings 
    define( 'WP_DEBUG_DISPLAY', false );
    @ini_set( 'display_errors', 0 );

    More on this in the following topic: Debugging in WordPress.

    Once the debug log is activated, please can you reproduce this issue? This way, when you’ll face this error again, we should be able to read the error. Then, could you share the content of your debug.log file with us please? You can post the content of this file as plain text in your next reply and mark it as private to keep this between us.

    After having reviewed your next reply, we’ll be able to tell you if the issue is caused by our product, a third party plugin or any type misconfiguration on your server. If we’re not able to help, we’ll recommend you to transfer the error logs to the plugin author or to your server hosting support.

    Thank you.

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez
    This reply has been marked as private.
    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    It’s quite big, sorry for that.

    So my devs told me the error 500 is due to because the page limit is removed and too much information is loaded. My idea was to keep the pagination on the members directory, but to remove the page limit only on the members Map.

    So basically what I want is to use the option in the attached image. Currently when I click on it, the whole thing disappears. Does that mean that when I click on it, the pagination is removed? It should not remove the pagination on the members directory because too many members need to be loaded.

    So the first step should be to remove the Map from the members page and keep the pagination on 40 members per page.

    Then step 2 should be to give the members Map it’s own page.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    It is correct. Due to your large number of members, there is too much information to load. For this reason, you get a 500 error.

    Please note that the snippet doesn’t work in the directory. I think you use the wrong term, you certainly mean the members list next to the map. Note that what you’re looking for is possible, but I’m afraid you’ll get the same result as the number of users to load is the same. 🤔

    Concerning the option in the screenshot you share with us, please be aware that it has nothing to do with the members map page. In fact, it is related to the Location tab in the user profile. When a member has a valid location, this location is displayed in the profile of this user.

    Let me know if you need more explanations René. 🙂

    Be aware that we have just released a new update of Grimlock for BuddyPress.

    Best,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Oops, I uploaded the wrong image. See the correct one attached. Before, it was possible to click on this and then the Map would disappear and only the members would be visible. Now if I click on it, everything disappears. Is there a way to not have the members disappear?

    But are you saying there is a limit on the amount of people than can be shown on the Map? I’m at 1500 members and it’s already too much? Thats crappy. Maybe I should look at another Map that is able to work with the members area?

    Ideally the Map could choose not to load all the members and would only be activated when a search on Location is performed. That way a maximum amount of members could be set and a message would appear if there are too many members to load. This would be the correct way to go. I’ll send Shane from Philopress a message about this. Curious to what he will say.

    What did the new Grimlock update bring?

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    I’m afraid at this point your questions are related to the behavior of the BP Maps for Members plugin. I will do my best to answer you. 🤔

    Regarding the option in your screenshot, it has certainly been modified by the PhiloPress team. I am afraid that changing this option will require custom development.

    It is indeed a shame that too many members to load is difficult to display. I think your solution might work. However, I suggest you also look at the server level. You could try increasing the limits of your server. It’s still a lot of members, but I think it might help.

    As we talked about an alternative in one of your previous topics, there aren’t many other solutions. However, we are open to feedback in case you have found something similar that might meet your needs. If so, please feel free to share this potential solution with us:

    Some members not found at location search

    It is indeed a good idea to reach out PhiloPress team about this. Don’t hesitate to share their feedback with us René. 🙂

    Best,

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Their response:

    Our plugin does not limit the number of members being processed – unless you set the number in the settings screen.
    If you do not set a limit and you get a 500 error – that means your server is out of resources, probably memory. We cannot control that.

    I will try to increase the limits. But I think it’s weird that I have to increase the limit, because that would indicate that if I disconnect the Map, that all members will be loaded. But that’s not what I want. I want the members limit to be kept on 40 per page.

    René Wappiez
    Participant
    • 106 Topics
    • 352 Posts
    @wappiez

    Further info:

    You are using both the map and the members on the same page – therefore you are using BP_User_Query twice and that loop will affect both areas.

    The solution is specific to your site / theme. You probably need to write a custom loop for the members listings. Or adjust how your theme handles the loop.

    Do you know someone who can help?

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 6712 Posts
    @themodactyl

    Hi René,

    Thank you for sharing their feedback with us.

    It seems that your solution is a good idea, as you’ll use only one query. 🙂

    We recommend you to require the services from Envato Studio freelancers (https://studio.envato.com/explore/websites-programming). This web platform gives you access to developers who have already experience with theme customizations, and for very competitive prices. We received really great feedbacks from our clients about Envato Studio freelancers.

    Best,

Roboraptor 🦖
Themosaurus Topic Closer

Hi there,

This topic has been inactive for a while now so we will be closing it to keep the forum tidy. Don't hesitate to create a new topic if you still need help and we'll be glad to help you!

Best regards,
The Themosaurus team.

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

The topic ‘Disconnect between Map and Members’ is closed to new replies.

Troubleshooting Demo Imports

You're trying to setup your theme but you're experiencing errors when importing the demo content? Or you've just followed the setup guide but your website doesn't look exactly like our demo? These are common issues for which you can find easy and quick fixes.

Happy With our Support So Far?

Feel free to review our theme on Themeforest! It helps us making our products more known to new potential customers, which allow us more time to improve the quality and develop new features. #SharingIsCaring ❤️

Discover MatchPress

Skip • Like • Super-Like

Add powerful matching features like Member likes, skips, super likes, conditional private messaging and much more.

Setup Your Cera or Gwangi powered Community Website and Turn it into an iOS and Android App

15% discount for Cera users

To unleash the full power of your Cera or Gwangi theme, we have partnered with the Zipline team. Your community website can now be fully setup and turned into your very own custom app for iOS and Android.

Whether you've newly acquired the theme or already got your site up and running, Zipline got you covered. And we got you an incredible discount.

Holiday, Weather & Festive effects
to pimp your WordPress Site