Add Homepage Bottom Pre-Genesis
Hi - I would like to add 2 homepage featured bottom sections to my website. Currently there is just one
I have seen some replies that relate to the genesis version of lifestyle, but I am running a pre-genesis version.
Can you please advise how I can add 2 additional homepage featured bottom sections?
I really appreciate the help!
Take a look at home.php to review how the original sections are coded and copy those elements you want to duplicate. You'll need to edit the post queries and rename the new divs and also add new style rules to the style sheet for the new divs.
Thank you - do I just copy the homppagebottom section and paste it below in the home.php? Do I need to change the name to something like homepagebottom1?
Below is the code from home.php for homepagebottom - do i just copy this (below)?
Do I need to change any other files to make sure it shows up in the Appearence - Lifestyle Theme Options?
I appreciate it!
<h3><?php echo __("The Latest Posts from . . . . the Travel Free Faster ", 'studiopress')." ".$cat->name; ?><?php echo cat_id_to_name(get_theme_mod('featured_bottom')); ?> </h3>
<?php $recent = new WP_Query("cat=".get_theme_mod('featured_bottom')." &showposts=".get_theme_mod('featured_bottom_num')) ; while($recent->have_posts()) : $recent->the_post();?>
<?php if( get_post_meta($post->ID, "thumb", true) ): ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><img class="thumb" src="<?php bloginfo('template_directory'); ?>/tools/timthumb.php?src=<?php echo get_post_meta($post->ID, "thumb", $single = true); ?>&h=<?php echo get_theme_mod('featured_bottom_thumb_height'); ?>&w=<?php echo get_theme_mod('featured_bottom_thumb_width'); ?>&zc=1" alt="<?php the_title(); ?>" /></a>
<?php else: ?>
<?php endif; ?>
<strong><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></strong>
<?php the_excerpt(__("[Read more...]", 'studiopress')); ?>
<?php endwhile; ?>
<?php $cat = get_category(get_theme_mod('featured_bottom')); ?>
<strong><a href="<?php echo get_category_link(get_theme_mod('featured_bottom') ); ?>" rel="bookmark"><?php echo __("Read More Great Posts from the TravelFreeFaster ", 'studiopress')." ".$cat->name; ?></a></strong>
Yes, you can copy that section. You will need to change all the IDs and option names. If you don't want to mess with the options you can replace those with a standard post query parameters.
|All times are GMT -5. The time now is 07:37 AM.|
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.