WordPress 2 Widget sidebars
Ok on David Naylor I hope you noticed the 2 widget sidebars, well here is the code:
in your Theme’s function.php
if (function_exists("register_sidebar")) { register_sidebar(Array("name" => "sidebar")); register_sidebar(Array("name" => "sponsors")); }
Then in your template to add for column 1
< ?php if (!function_exists('dynamic_sidebar') or !dynamic_sidebar("sidebar")) { ?> etc.. < ?php } ?>
and likewise for column 2
< ?php if (!function_exists('dynamic_sidebar') or !dynamic_sidebar("sponsors")) { ?> etc.. < ?php } ?>
screen shoot for Admin panel on it
![]()
DaveN





Brad 2138 days ago
http://www.netevolution.co.ukHi Dave,
Is there a wordpress plugin you used to display code in this post?, I am new to blogging but want to put code samples up in wordpress.
If you could let me know I’d be much obliged
Brad
Neil 2060 days ago
http://www.neilduckett.comDetailed instructions but i wasn`t able to get it to work. Any luck with the plugin Brad??
Tom 1938 days ago
This is great, but when you say ‘Then in your template to add for column 1′, what template do you mean? Which file do you edit here?
Thanks.
vapparel 1715 days ago
http://www.vapparel.netI will try your widget sidebars.then i will tell you .
Vasiliy Nesterenko 1620 days ago
Thank’s! It’s very simple, and geniously =)
Louis 1580 days ago
http://www.impressivewebs.comThank you, this was helpful to add a second widget bar.
Raol 1495 days ago
http://www.pradyumasinh.comThanks for the code..!
And must say really nice design.. specially the comment area..
gaetangat 1455 days ago
Hi,
Really nice and easy solution. You make my day
Do you know if there is any possibility to add the same widget on both sidebars?
Thanks a lot.
helpful 1439 days ago
thank you, +1 karma for you!
George 1150 days ago
Hy. Thanks for the code.
I had some problems with the template syntax but i managed to solve it/ For others who might experience problems with the column template syntax i suggest just using the sidebar.php syntax for the dynamic_sidebar and change
|| !dynamic_sidebar( )) : ?>
|| !dynamic_sidebar(‘sponsors) ) : ?> or which ever name you chose for your sidebar