Widgetizing a custom sidebar
-
I think I’m doing this wrong:
I’m trying to put in a custom sidebar, so I made a file named “sidebar-optional.php”.
In the file I put:
<div id="optionalsidebarcss"> <ul style="list-style: none;"> <?php if ( function_exists ( dynamic_sidebar(sidebar-optional) ) ) : ?> <?php dynamic_sidebar (sidebar-optional); ?> <?php endif; ?> </ul> </div>
In the functions.php file I put:
<?php if ( function_exists ('register_sidebar')) { register_sidebar ('sidebar-optional'); } ?>
However, any widgets I put in this sidebar won’t show up.
Any suggestions?
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Widgetizing a custom sidebar’ is closed to new replies.