Where did the Widgets Go? Using Widget Areas in Oxygen Builder 6

Posted on - 20-01-260 Comments

If you are following an older Oxygen tutorial, you might notice a common instruction: "Go to +Add > WordPress > Sidebars." But in Oxygen Builder 6, many users find that the "Sidebars" category is missing entirely. This happens because Oxygen is "Theme-less"—since it replaces the theme, WordPress sometimes doesn't realize you want to use classic widget areas.

Here is the skillful way to register and display custom sidebars in the modern Oxygen environment.


Step 1: Registering the Sidebar (The Foundation)

Before Oxygen can display a sidebar, WordPress needs to know it exists. Since you don't have a functions.php (because Oxygen disables your theme), you should use a plugin like Advanced Scripts or Code Snippets to run this PHP:

PHP

<?php
add_action( 'widgets_init', 'register_custom_oxygen_sidebar' );

function register_custom_oxygen_sidebar() {
    register_sidebar( array(
        'name'          => 'Oxygen Custom Widgets',
        'id'            => 'oxygen-custom-widgets',
        'before_widget' => '<div class="widget-wrapper">',
        'after_widget'  => '</div>',
    ) );
}

Once this is saved, you can go to Appearance > Widgets in your WordPress dashboard and you will see your new "Oxygen Custom Widgets" area ready for content.


Step 2: Why the "Sidebars" Element is Missing

In Oxygen 6, if the builder doesn't detect a traditional theme structure, it simplifies the +Add menu.

You might see a Widget element, but this usually forces you to pick a single widget (like a search bar or a calendar). If you want to display the entire area you just registered, the standard Widget element feels limiting.


Step 3: The "Skillful" Solution – The Code Block Method

The most reliable way to display a sidebar in Oxygen 6 is to use a Code Block. This bypasses any UI bugs and gives you full control over the HTML wrapper.

  1. In Oxygen, click +Add > Basics > Code Block.
  2. Navigate to the PHP & HTML tab.
  3. Paste the following logic:

PHP

<?php if ( is_active_sidebar( 'oxygen-custom-widgets' ) ) : ?>
    <div id="primary-sidebar" class="primary-sidebar widget-area" role="complementary">
        <?php dynamic_sidebar( 'oxygen-custom-widgets' ); ?>
    </div>
<?php endif; ?>

Why this is the preferred method:

  • Clean Output: It only renders the <div> if the sidebar actually has widgets in it (preventing empty white space).
  • Zero Dependencies: You aren't relying on Oxygen’s internal "WordPress" category elements which can change between versions.
  • Full Control: You can easily change the CSS IDs or classes to match your site's styling.

Summary Table: Which Element Should You Use?

MethodBest Used For...Why?
Widget ElementSingle ItemsBest for placing one specific tool (like a Search bar).
Shortcode ElementQuick FixesGood if you use a plugin that provides a sidebar shortcode.
Code BlockComplete SidebarsRecommended. The most stable way to render a full Widget Area in Oxygen 6.

Export to Sheets


Final Thought

Oxygen Builder 6 gives us more power, but it requires us to be a bit more intentional with how we handle "legacy" WordPress features like Sidebars. By registering your own area and calling it via a Code Block, you create a future-proof setup that won't break during the next update. Once Oxygen Builder Dev's make a fix this will surely become redundant. After creating add widgets from the appearance > Customize screen which gives somewhat a tolerable control.

Leave a Reply

linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram