Introduction
Any code you add under Theme Options > Custom Codes in BuddyBoss loads on every page of your site. To target only specific parts, wrap your code in selectors (IDs or classes) so it executes in the desired context.
Core Information
- Global Injection: Custom HTML, CSS, or JavaScript entered here is output in the header or footer of all pages.
- Selective Targeting: Use unique IDs or classes in your code to ensure effects apply only to specific elements or templates.
Troubleshooting and FAQs
Q: Will large amounts of custom code impact site performance?
A: Potentially—minify your script and only include what’s necessary. Consider loading heavy scripts via a plugin or enqueueing them conditionally in your child theme.
Q: I added CSS that’s not taking effect—why?
A: Ensure your selectors are specific enough and that your custom CSS loads after all other styles. You may need to use !important sparingly.
Q: Can I use PHP snippets in Custom Codes?
A: No—this field supports only HTML, CSS, and JavaScript. For PHP, add code to your child theme’s functions.php or a custom plugin.
Q: Who can I contact for assistance?
A: Submit a support ticket via your BuddyBoss account dashboard for personalized guidance.