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)
-   -   How to customize sidebars based on page (http://forum.bytesforall.com/showthread.php?t=1535)

guacamoly May 4, 2009 03:21 AM

How to customize sidebars based on page
 
Does any one know how to customize the sidebar content based on what page is currently being viewed?

Also Is there a way to add items to a sidebar without it being a widget?

Thanks a lot

Flynn May 5, 2009 05:46 PM

CSS Insert:

body#body-page-13 td#right div.widget {
...
}

This would address all widgets in the right sidebar on the page with the ID 13

Look into the source code to see the ID and classes that are being added to the <BODY> tag for every page

The text widget is transparent, you can leave out the title and then it'd be like manually editing the sidebars. If you still want to manually edit the sidebars put your code into header.php (left sidebar) or footer.php (right sidebar) before or after

PHP Code:

            <?php // Widgetize the Left Sidebar
            
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar(1) ) :
            endif; 
?>

In some theme versions there's some text after the :


All times are GMT -6. The time now is 05:45 PM.

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