Support » Fixing WordPress » how to hardcode plugins into wp

  • how do you code plugins into the sites core? i want to keep my plugins neat and small and there’s a lot of things i think could just be added straight into my db. anyone know how to achieve this?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Moderator Steven Stern (sterndata)


    Support Volunteer

    Do not modify core files — that’s why there are plugins. The code works the same whether in a plugin, theme, or core.

    @sterndata could i ask why? other than the inability to update the plugins if they were in our wp-core.

    We just simply want to organize our interface a bit and especially our plugins list. hardcoding seemed like the solution but we’ve held off on it until we know more about it

    “Blackhole for Bad Bots” and “Block Bad Queries (BBQ)” and many other plugins provide functionality that we want running constantly (i.e we never plan to remove/deactivate these), and we’d just like to code it in so that we no longer have to see it in our plugins list.
    this will eliminate “junk” or unimportant plugins to read through while editing/adding/deleting plugins…

    If, by your own admission, the code works exactly the same as a plugin or hardcoded in, I don’t understand why we should not hardcode them into our core.

    Are you worried about security (sanitizing/escaping)?

    Moderator Steven Stern (sterndata)


    Support Volunteer

    Then use mu-plugins

    If you modify core, you can’t update.

    @sterndata thank you we’ll just do that

    How do we create proxy php loader files? I read on the link you referrenced that wp doesn’t search folders and subfolders in /mu-plugins like /plugins does so how do I link them?

    for example:
    I have blackhole.php in MU. And I also have the B4BB folder (minus blackhole.php which is of course one level up in /mu-plugins).

    so how do I allow blackhole.php in /mu-plugins/ to load
    blackhole-core.php from /mu-plugins/blackhole-for-bad-bots/inc/?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘how to hardcode plugins into wp’ is closed to new replies.