User Profiles critical error

#1064186
  • Resolved Jim Sharp
    Rank Math free

    When I in WP console looking at Users and click on View for any user, I get a page with the following error information:

    Uncaught Error: Call to undefined function RankMath\BuddyPress\bp_members_get_user_url()
    in /home/u121091148/domains/ozarksbiker.com/public_html/wp-content/plugins/seo-by-rank-math/includes/modules/buddypress/class-buddypress.php on line 88

    Call stack:

    RankMath\BuddyPress\BuddyPress::json_ld()
    wp-includes/class-wp-hook.php:326
    WP_Hook::apply_filters()
    wp-includes/plugin.php:256
    apply_filters_ref_array()
    wp-content/plugins/seo-by-rank-math/includes/traits/class-hooker.php:106
    RankMath\Schema\JsonLD::do_filter()
    wp-content/plugins/seo-by-rank-math/includes/modules/schema/class-jsonld.php:149
    RankMath\Schema\JsonLD::json_ld()
    wp-includes/class-wp-hook.php:324
    WP_Hook::apply_filters()
    wp-includes/class-wp-hook.php:348
    WP_Hook::do_action()
    wp-includes/plugin.php:565
    do_action_ref_array()
    wp-content/plugins/seo-by-rank-math/includes/traits/class-hooker.php:90
    RankMath\Frontend\Head::do_action()
    wp-content/plugins/seo-by-rank-math/includes/frontend/class-head.php:180
    RankMath\Frontend\Head::head()
    wp-includes/class-wp-hook.php:324
    WP_Hook::apply_filters()
    wp-includes/class-wp-hook.php:348
    WP_Hook::do_action()
    wp-includes/plugin.php:517
    do_action()
    wp-includes/general-template.php:3192
    wp_head()
    wp-content/themes/buddyboss-theme/header.php:17
    require_once(‘/home/u121091148/dom…oss-theme/header.php’)
    wp-includes/template.php:810
    load_template()
    wp-includes/template.php:745
    locate_template()
    wp-includes/general-template.php:48
    get_header()
    wp-content/themes/buddyboss-theme/buddypress.php:10
    include(‘/home/u121091148/dom…theme/buddypress.php’)
    wp-includes/template-loader.php:106
    require_once(‘/home/u121091148/dom…/template-loader.php’)
    wp-blog-header.php:19
    require(‘/home/u121091148/dom…l/wp-blog-header.php’)
    index.php:17
    Query Monitor

    When I visit my site as a user and click on a member profile (including my own) I get a critical error page. When I Disable RankMath, everything works fine.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Hello,

    I apologize for the issue you are facing with the critical error related to the Rank Math plugin and BuddyPress. This error indicates that the function bp_members_get_user_url() is not defined, which can happen due to a conflict or an issue with the BuddyPress integration in Rank Math.

    To troubleshoot this issue, you can try the following steps:

    1. Ensure BuddyPress is Installed and Active: Make sure that the BuddyPress plugin is installed and activated on your site, as this function is part of BuddyPress.

    2. Update Plugins: Ensure that both Rank Math and BuddyPress are updated to their latest versions. Sometimes, compatibility issues arise from outdated plugins.

    3. Check for Conflicts: Deactivate other plugins temporarily to see if there’s a conflict causing this issue. If the error disappears after deactivating a specific plugin, that plugin may be causing the conflict.

    4. Switch Themes: Temporarily switch to a default WordPress theme (like Twenty Twenty-One) to see if the issue persists. If it resolves, the problem may lie within your current theme.

    5. Debugging: Enable debugging in WordPress by adding the following line to your wp-config.php file:

      define( 'WP_DEBUG', true );

      This will help you see more detailed error messages that might provide further insight into the issue.

    If these steps do not resolve the issue, please reply to this ticket with your site URL so that a human agent from our support team can assist you further. Thank you for bringing this concern to our attention!

    Sources:
    Sorry, You Are Not Allowed to Access This Page » Rank Math

    Hello,

    Thank you for your query and we are so sorry about the trouble this must have caused.

    There’s a possibility that you’re using an old version of BuddyPress so please make sure that you have updated the plugin.

    If the issue persists, do let us know and we’ll assist you further. Looking forward to helping you.

    All of my plugins are up to date, as they were at the time I opened the case. The issue persists so long as RankMath is Active. The moment I Deactivate RankMath, profiles work fine.

    Hello,

    This issue has already been reported to our development team, and they are already investigating it.

    We will notify everyone via the usual communication channels once this issue is resolved and the update is added.

    We appreciate your kind patience with this matter.

    Thank you.

    Hello,

    A fix for this issue will be included in a later plugin update.

    In the meantime please change line 88 of wp-content > plugins > seo-by-rank-math > includes > modules > buddypress > class-buddypress.php from:
    'url' => esc_url( bp_members_get_user_url( $user_id ) ),

    to
    'url' => ! function_exists( 'bp_members_get_user_url' ) ? esc_url( bp_core_get_user_domain( $user_id ) ) : esc_url( bp_members_get_user_url( $user_id ) ),

    Alternatively, you can upload the following Rank Math FREE zip file, which has the patch on your site: https://i.rankmath.com/f/cYNOcy

    Kindly also reach out to the plugin authors to include prefixes in their class|function names to avoid such conflicts, as recommended by WordPress: https://developer.wordpress.org/plugins/plugin-basics/best-practices/

    We hope this helps. Please let us know if you have further questions or concerns.

    Thank you.

    @rankbot, this is happening same with our website. If I deactivate rank math then author profile working fine. otherwise profile is not working ” There has been a critical error on this website.”

    Please suggest me what to do. Our website author profile is.

    Hello,

    You must have received an email from WordPress with the details about the error. Please share it with us here so we can check and assist you further.

    If you haven’t received the email with the error code, you can follow this guide to enable debugging in WordPress
    https://wordpress.org/support/article/debugging-in-wordpress/ or you can get in touch with your web host, and they will help you locate the log file.

    Having an error log will help us determine what is causing the critical error on your website.

    You can trigger again the error so the log would be updated.

    Looking forward to helping you.

    Thank you.

    Erric Ravi
    Rank Math free

    I will check and get back to you

    Hello,

    Sure, let us know how this goes.

    Meanwhile, please don’t hesitate to contact us anytime if you have other questions to assist you further.

    Looking forward to helping you.

    Thank you.

    Hello,

    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 9 replies - 1 through 9 (of 9 total)

The ticket ‘User Profiles critical error’ is closed to new replies.