Dismiss Notice – 404 error

Home Forums BulletProof Security Free Dismiss Notice – 404 error

This topic contains 2 replies, has 2 voices, and was last updated by  Adendum 3 years, 1 month ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #22343

    Adendum
    Participant

    I have just installed BPS Free into an established site and this is a new set up. In installed using Firefox and set up the plugin as normal. I added three of the bonus codes and dismissed notices for each one while in Admin. I then logged in as one of the editors, using Chrome, and the Dismiss Notice button gives me a 404 page?!? I logged out of Chrome and logged back in as the same editor using Firefox and the same problem happens.

    WP 4.2.1
    BPS .51.7

    #22346

    AITpro Admin
    Keymaster

    This has been fixed in BPS .51.8.  The issue is when you first login to your site you have a literal URL of:  /wp-admin.  So for now click on the WordPress Dashboard link to get an URL like this:  /wp-admin/index.php or any other link in your Dashboard and the Dismiss Notice will be dismissed correctly.

    Code in BPS .51.7:

    if ( esc_html($_SERVER['QUERY_STRING']) == '' ) {
    $bps_base = basename(esc_html($_SERVER['REQUEST_URI'])) . '?';
    } else {
    $bps_base = str_replace( admin_url(), '', esc_html($_SERVER['REQUEST_URI']) ) . '&';
    }

    Code in BPS .51.8:

    if ( esc_html($_SERVER['QUERY_STRING']) == '' && basename(esc_html($_SERVER['REQUEST_URI'])) != 'wp-admin' ) {
    $bps_base = basename(esc_html($_SERVER['REQUEST_URI'])) . '?';
    } elseif ( esc_html($_SERVER['QUERY_STRING']) == '' && basename(esc_html($_SERVER['REQUEST_URI'])) == 'wp-admin' ) {
    $bps_base = basename( str_replace( 'wp-admin', 'index.php?', esc_html($_SERVER['REQUEST_URI'])));
    } else {
    $bps_base = str_replace( admin_url(), '', esc_html($_SERVER['REQUEST_URI']) ) . '&';
    }
    #22348

    Adendum
    Participant

    Yup, that fixed it. Thanks for the RAPID response!!

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

You must be logged in to reply to this topic.