has travelled Asia

Blog

Show all posts in archives

change the number in archive.php to -1:

<?php
query_posts($query_string.’&posts_per_page=-1′);
if (have_posts()) : ?>


Show sidebar on home page only

Once I wanted to show the sidebar on my home page only. Searching offered quite some ways in doing so, like changing sidebar.php or page.php, I chose:

<?php if ( is_front_page() ) { ?>
your sidebar.php
<?php } ?>

However these had still the drawback that pages were still divided in two columns and the respective commands interfered with other settings. As I didn’t find a satisfying solution I had to made one up, which I want to share with you. It’s  independent from all other settings as functions.php, i.e. the modularity_sidebar_class() function is directly modified to:

$options = get_option( ‘modularity_theme_options’ );
if ( is_home() ) {echo “15 colborder home”;}
else {echo “24 last”;}

I just changed the if-condition. Maybe this is what some of you want, too. (According to your settings you might want to change it rather to is_front_page() or whatever.)


,