I should also mention that in the widget section (where you drag and drop) it does in fact show the 2 sidebars rather than just one like in the default or classic theme.
This tells me that it is at least connected somehow, right?
I’m thinking I have to code in whatever widget I want in the order and side I want in the actual sidebar.php file but I really don’t see why this should be necessary nor do I know where to look for the code for each widget.
I don’t mind messing with the code at all if onlyI knew what needs to go there.
-Fizzy
Ok well I’m having *Some* progress…
And by the way, I realize this maybe is in the wrong forum and I’m sorry about that (no idea how to move it to widgets area?).
Anyhow,
I have managed to get the widgets to show in one or both of the sidebars by changing the code:
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar('Sidebar_1') ) : else : ?>
With:
<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar() ) : ?>
But of course it’s 2 sidebars and without a label for them individually, it comes out as the first sidebar for both of them (so whatever I put in the #1 bar will also show in #2)
So now I ask, please can someone help me with what I should put in:
<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar(>>HERE<<) ) : ?>
Because ‘Sidebar_1’, ‘sidebar_1’ and ‘left-sidebar’ Do not work at all.
Same with 2.
Thanks a bunch.
-Fizz
Can no one help me with this? Still stuck.
I can’t help You with that, but I’m working on the same problem, might be helpful to go to the JD site. If you get any further concerning this problem, pls. let me know.
Regards,
Kay
I would consult the Codex on widgets. IMHO your theme functions.php is borked.
Yes… I had a look at the JD-Site. I downloaded that 2 columns theme and tried it, it is working. Then I downloaded the 3 columns theme again, hoping that it is fixed already, but it isn’t.
Had a look at funktions.php:
if ( function_exists(‘register_sidebar’) ) {
register_sidebars(2, array(
‘name’ => ‘Sidebar_%d’,
‘before_widget’ => ”,
‘after_widget’ => ”,
‘before_title’ => ‘<h3>’,
‘after_title’ => ‘</h3>’,
));
}
I replaced ‘Sidebar_%d’ with ‘Sidebar_1’, I got this name from sidebar.php, now it’s partly working as Fizzgig mentioned. But how to use widgets on both sidebars?
I’m quite new to php and css and need some help I guess.
Thx,
Kay
Any progress on this? I just downloaded this theme as well and am having the same issue.
Hi,
I used jd-nebula as the basis for my own theme and ran into the same problem. Searching around the forums, I found a potential solution. Don’t know if my hack is good code, but it works to my satisfaction:
<div id="left-sidebar">
<ul>
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar(1) ) : else : ?>
<?php wp_list_pages('title_li=<h2>' . __('Pages') . '</h2>' ); ?>
<li>
<div id="categories">
<h3><?php _e('Categories:'); ?></h3>
<ul>
<?php wp_list_cats('sort_column=name&optioncount=1&feed=rss'); ?>
</ul>
</div>
</li>
<li>
<div id="archives">
<h3><?php _e('Archives:'); ?></h3>
<ul>
<?php wp_get_archives('type=monthly&show_post_count=1'); ?>
</ul>
</div>
</li>
</ul>
<?php endif; ?>
</div>
<div id="right-sidebar">
<ul>
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar(2) ) : else : ?>
<?php wp_list_pages('title_li=<h2>' . __('Pages') . '</h2>' ); ?>
<li>
<h3>Calendar</h3>
<?php get_calendar(); ?>
</li>
<li>
<div id="blogroll">
<h3>Blogroll</h3>
<ul>
<?php get_links(-1, '<li>', '</li>', ' - '); ?>
</ul>
</div>
</li>
<li>
<div id="meta">
<h3><?php _e('Meta:'); ?></h3>
<ul>
<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<li><a href="http://wordpress.org/" title="<?php _e('Powered by WordPress, state-of-the-art semantic personal publishing platform.'); ?>"><abbr title="WordPress">WP</abbr></a></li>
<?php wp_meta(); ?>
</ul>
</div>
</li>
</ul>
<?php endif; ?>
</div>
Basically, I replaced
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar('Sidebar_1') ) : else : ?>
with
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar(?) ) : else : ?>
<?php wp_list_pages('title_li=<h2>' . __('Pages') . '</h2>' ); ?>
(change ? in dynamic_sidebar(?) to 1 for the left sidebar and 2 for the right sidebar)
Then I wrapped each sidebar in a <ul>
tag, and wrapped each sidebar module in <li>
tags.
After reading the other entries, I did something similar to GrillSgt…
functions.php:
<?php
if ( function_exists('register_sidebar') ) {
register_sidebar(array(
'name' => 'Sidebar_1',
'before_widget' => '',
'after_widget' => '',
'before_title' => '<h3>',
'after_title' => '</h3>'
));
register_sidebar(array(
'name' => 'Sidebar_2',
'before_widget' => '',
'after_widget' => '',
'before_title' => '<h3>',
'after_title' => '</h3>'
));
}
?>
sidebar.php:
Replace
dynamic_sidebar('Sidebar_1')
with dynamic_sidebar(1)
and
dynamic_sidebar('Sidebar_2')
with dynamic_sidebar(2)
I don’t know if this is a changed behaviour in WP 2.3.2, it’s the first time I get widgets working, and I love the jd-nebula-3c-10 theme 🙂