Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Sidebars & Widgets (http://forum.bytesforall.com/forumdisplay.php?f=14)
-   -   [SOLVED] New widget area only on specified page? (http://forum.bytesforall.com/showthread.php?t=4103)

horsemansarts Oct 28, 2009 08:10 AM

[SOLVED] New widget area only on specified page?
 
I've created a new widget area that appears below the center content area. This works out great. I've used widget logic to make it so that my widgets display only on the the front page. This also works great. I've added css to style the new widget area to be a different color than the background on the center area. Also works great.

The problem is although the widgets do not display on the inner pages, the widget area is still there. One can tell because there is a block of the different colored background visible. So, my question is, can I, as I can with side bars, cause wp not to show the widget area on inside pages? Or maybe this is done with css?

Thanks!
Sharon

juggledad Oct 28, 2009 11:29 AM

you should be able to add a pfp IF with the new area.

Lets say you wanted a new widget area in the header, but only on page ID=21 you could use
HTML Code:

<?php if (is_page(21)) { bfa_widget_area('name=My header widget area'); } ?>
and the area should only exist on page id=21

horsemansarts Oct 28, 2009 03:37 PM

WAY cool. It worked! :-)

Sharon


All times are GMT -6. The time now is 05:49 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.