• Resolved crzyhrse

    (@crzyhrse)


    Hi Fakhri,

    A while back you created a little plugin to fix how your plugin was redirecting bbpress forum profile links to the 404 page I have set in your plugin… It continues to do that, but I have discovered that when it is active the setting in your plugin doesn’t work, any non-existent or broken url go to a blank page…

    When I deactivate your little bbpress user profile link fix plugin then the redirect to the 404 works again, but the bbpress user profile links are broken again, and go to the 404 page as well…

    When your seo redirection plugin is not active the bbpress links work just fine, no need for the little plugin you made… So it seems basically that the little plugin is only deactivating your seo redirection’s 404 redirect setting…?

    So, as it is, I have the choice of either the forum profile links don’t work, or there is a blank page found when there is a broken url, instead of the page I’ve set up for that, with a menu and search bar…

    I have no idea how long this has been going on… I just discovered it while working on something else…

    I have your pro version…

    Hoping for a real fix for this…?

    Kind regards…

    https://www.ads-software.com/plugins/seo-redirection/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter crzyhrse

    (@crzyhrse)

    In case you have forgotten this, here is the content of the little plugin…

    /*
    Plugin Name: bbPress 404 Error Fix
    Plugin URI: https://www.clogica.com
    Description: Fixes 404 errors when viewing user profiles.
    Version: 1
    Author: Fakhri Alsadi
    Author URI: https://www.clogica.com
    */

    function bbp_fix_users_404_headers() {
        if ( ! function_exists( 'bbpress' ) ) return;
        $bbp = bbpress();
    
        if ( !empty( $bbp->displayed_user ) && is_404() ) {
            global $wp_query;
            $wp_query->is_404 = false;
            status_header( 200 );
        }
    }
    add_action( 'wp', 'bbp_fix_users_404_headers' );

    Thread Starter crzyhrse

    (@crzyhrse)

    In case you have forgotten about this, I sent you the content of the little plugin via the contact form on your site…

    Hi,

    Sorry for the delay, I will investigate and follow up the issue and back to you soon with any updates.

    Regards,
    Clogica

    I replied you at your email with the detailed steps to solve this issue.

    I had the same error i did this piece of code and the status code will be force to be 200 in my case was when i was showing the user public profile.

    function bbp_fix_users_404_headers() {
      if (bp_displayed_user_id() != 0 && is_404() ) {
        global $wp_query;
        $wp_query->is_404 = false;
        status_header( 200 );
      }
    }
    add_action( 'wp', 'bbp_fix_users_404_headers',0 );
    Thread Starter crzyhrse

    (@crzyhrse)

    Just to add, Fakhri, I haven’t had a resolution on this, the email with steps you sent did not resolve the issue for me… I replied to that email telling you that, and haven’t heard from you any further… Refer again to my first message above here for the details in my case…

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘bbpress profile links verses having a 404 page…’ is closed to new replies.