Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Header configuration & styling (http://forum.bytesforall.com/forumdisplay.php?f=15)
-   -   [SOLVED] Layout WIDTH vs. Layout Container (http://forum.bytesforall.com/showthread.php?t=2401)

Olivier Jul 13, 2009 07:44 AM

[SOLVED] Layout WIDTH vs. Layout Container
 
Hi,

First of all, congratulations on a fantastic Theme. I have stuggled in the past with other themes to make them work for me; now I have found one that indeed I do not have to fight with to get excellent results... So BIG thanks for this ;)

OK, on with my question...:

Is there a way to define the layout width and the layout container in an independent way? I explain. I would like to be able to set the width of the Header, Page Bar, Category Bar, and Footer to a different width than the in-between section namely, sidebars and center column. So that I can for instance set the width of the Header, Page Bar, Category Bar, and Footer to 100%, while the in-between section (sidebars and center column) set at say 90%

Anyone can help with this one?

Many thanks

Cheers,

Olivier

Flynn Jul 13, 2009 10:08 AM

You cannot as header, body (with sidebars and middle column) and footer are one single table.

You may be able to achieve the effect you're looking for by putting divs into the sidebars and setting a left padding on the left sidebar and a right padding on the right sidebar


header.php


<?php if ( $bfa_ata['left_col'] == "on" ) { ?>
<!-- Left Sidebar -->
<td id="left">
<div id="left-sidebar">
<?php // Widgetize the Left Sidebar
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Left Sidebar') ) : ?>

<div class="widget widget_categories"><div class="widget-title">
<h3><?php _e('Categories','atahualpa'); ?></h3>
</div><div class="widget-content">
<ul>
<?php wp_list_categories('show_count=1&title_li='); ?>
</ul>
</div></div>

<div class="widget widget_archive"><div class="widget-title">
<h3><?php _e('Archives','atahualpa'); ?></h3>
</div><div class="widget-content">
<ul>
<?php wp_get_archives('type=monthly'); ?>
</ul>
</div></div>

<?php endif; ?>
</div>
</td>
<!-- / Left Sidebar -->
<?php } ?>




and footer.php


<?php if ( $bfa_ata['right_col'] == "on" ) { ?>
<!-- Right Sidebar -->
<td id="right">
<div id="right-sidebar">
<?php // Widgetize the Right Sidebar
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Right Sidebar') ) : ?>

<div class="widget"><div class="widget-title">
<h3>Recent Posts</h3></div><div class="widget-content">
<?php $r = new WP_Query(array(
'showposts' => 20,
'what_to_show' => 'posts',
'nopaging' => 0,
'post_status' => 'publish',
'caller_get_posts' => 1));
if ($r->have_posts()) : ?>
<ul>
<?php while ($r->have_posts()) : $r->the_post(); ?>
<li><a href="<?php the_permalink() ?>"><?php if ( get_the_title() ) the_title(); else the_ID(); ?> </a></li>
<?php endwhile; ?>
</ul>
<?php wp_reset_query(); // Restore global post data stomped by the_post().
endif; ?>
</div></div>

<div class="widget"><div class="widget-title">
<?php wp_list_bookmarks('category_before=&category_after =&title_before=<h3>&title_after=</h3></div><div class="widget-content">'); ?>
</div></div>

<div class="widget"><div class="widget-title">
<h3><?php _e('Meta','atahualpa'); ?></h3>
</div><div class="widget-content">
<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.','atahualpa'); ?>">
<?php _e('WordPress','atahualpa'); ?></a></li>
<?php wp_meta(); ?>
</ul>
</div></div>

<?php endif; ?>
</div>
</td>
<!-- / Right Sidebar -->
<?php } ?>



Theme Options -> Stye & Configure SIDEBARS

LEFT Sidebar Style:
padding: 10px 10px 10px 150px;


RIGHT Sidebar Style:
padding: 10px 150px 10px 10px;

Olivier Jul 13, 2009 06:18 PM

Thanks Flynn. Wow! I sure appreciate the fast reply on this. Still need to try it and decide upon visualisation of the results. Still, Thanks for the feedback. Great stuff.

Many thanks,

Cheers,

Olivier


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

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