Skip to:
Content
Pages
Categories
Search
Top
Bottom

functions.php or bp-custom.php?

  • When adding custom functions to a child theme is there any benefits between adding them in your themes functions.php or adding them to bp-custom.php in the plugins folder?

Viewing 4 replies - 1 through 4 (of 4 total)
  • @djpaul

    Keymaster

    bp-custom.php is loaded before most of BuddyPress is loaded, and a theme’s functions.php is loaded later in a process. Functions.php is also specific to a theme, and bp-custom.php isn’t.

    Because bp-custom.php loads before BP is complete could that effect BP functions contained within the bp-custom.php plugin?

    @djpaul

    Keymaster

    Yes, that’s the whole point. Or you could put all your custom code into a utility plugin, and load it that way. There’s many ways to do the same thing (load code to use in a theme) and which is best depends on the situation.

    Thanks that confirms what I was thinking. :)

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘functions.php or bp-custom.php?’ is closed to new replies.
Skip to toolbar