Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: I would add a fourth-section, but the widgets?


21cdb
Participant

@21cdb

In ur themes function.php (create one if it doesn’t exist in ur theme folder) add

<br />
/* Register an additional fourth widget column */<br />
register_sidebars( 1,<br />
array(<br />
'name' => 'fourth-section',<br />
'before_widget' => '<div id="%1$s" class="widget %2$s">',<br />
'after_widget' => '</div>',<br />
'before_title' => '<h2 class="widgettitle">',<br />
'after_title' => '</h2>'<br />
)<br />
);<br />

and alter the code in ur post above to

<div id="fourth-section" class="widget-section"><br />
<?php if ( !function_exists('dynamic_sidebar')<br />
|| !dynamic_sidebar('fourth-section') ) : ?></p>
<p> <div class="widget-error"><br />
<?php _e( 'Please log in and add widgets to this section.', 'buddypress' ) ?> /wp-admin/widgets.php?s=&show=&sidebar=first-section"><?php _e( 'Add Widgets', 'buddypress' ) ?><br />
</div></p>
<p> <?php endif; ?></p>
<p> </div>

This should bring u a functional fourth-section sidebar in the wordpress backend. Valid for BP 1.1.3 Theme.

Skip to toolbar