Bootstrap Shortcodes for WordPress – plugin scripts loaded on BPS Pro plugin pages

Home Forums BulletProof Security Pro Bootstrap Shortcodes for WordPress – plugin scripts loaded on BPS Pro plugin pages

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #31160
    Tina Dubinsky
    Participant

    Hi

    Sorry if this posts twice, I thought I had submitted it (went through the process but it didn’t show up). So here goes a second attempt.

    On one of my websites, I’ve recently installed Bootstrap 3 Shortcodes plugin. BPS Pro and Bootstrap 3 appear to be sharing the same space in the admin area.

    When I go to the BPS Pro pages in the admin panel, Bootstrap 3 info appears under the BPS Pro information on the same page.

    This seems to be an aesthetic issue rather than a performance issue as both plugins seem to be working okay its just this shared space issue in the admin area. While I can read and still use BPS Pro, I can’t quite read the Bootstrap 3 information that appears beneath BPS pro pages.

    Hope this makes sense. Happy to post a screen capture if needed to show what I’m talking about.

    Cheers
    -Tina

    #31163
    AITpro Admin
    Keymaster

    I will download, install and test the Bootstrap Shortcodes for WordPress plugin and see what is going on.  I checked what the plugin does and I don’t see any reason why this plugin should be loading its scripts in BPS Pro plugin pages.  Will know more after testing.

    #31166
    AITpro Admin
    Keymaster

    The plugin author just forgot to add a condition in this file:  /bootstrap-3-shortcodes/includes/bootstrap-shortcodes-help.php on code line:  90 to limit/restrict the documentation popup modal HTML code to only load on these WordPress pages:  ‘post.php’, ‘page.php’, ‘page-new.php’, ‘post-new.php’, ‘widgets.php’, ‘admin-ajax.php’.  I see that a condition to only load the Boostrap help file code was done in their media_buttons action hooks in other code in this plugin.  So it just looks like they missed a spot.  If you would like to modify the Bootstrap Shortcodes for WordPress plugin code to prevent this plugins code from loading on BPS Pro plugin pages then do the steps below.  Also please post a link to this forum topic in the Bootstrap Shortcodes for WordPress plugin support forum so they can fix this permanently in the next version release of this plugin.

    1. Add this new conditional code modification below to this file: /bootstrap-3-shortcodes/includes/bootstrap-shortcodes-help.php on code line: 90. All yellow highlighted code below is the new code modification that you will be adding/creating:

    <?php
    // ======================================================================== //
    // Create the documentation popup modal
    // ======================================================================== //
    global $pagenow;
    if ( 'post.php' == $pagenow || 'page.php' == $pagenow || 'page-new.php' == $pagenow || 'post-new.php' == $pagenow || 'widgets.php' == $pagenow || 'admin-ajax.php' == $pagenow ) {
    ?>
    ...
    ...
    ...
    <?php }
    // ======================================================================== //
    ?>
    #31203
    Tina Dubinsky
    Participant

    Ah, thanks so much for looking into it. I really appreciate the extra effort and I have copied and changed my plugin and its all back to looking normal. I’ve also posted a link to this discussion on their support page.

    Cheers,
    -Tina

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.