StudioPress Community Forums
  StudioPress Community Forums > Forums > General Discussion
For help and support, access to your downloads, or to manage your account please log into My StudioPress.

These forums have been set to read-only so you can browse the existing topics for any questions you may have.

For general discussion on WordPress, CSS and design (NOT for support) visit the new Community Forums.
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 05-24-2012, 10:37 AM
sarova sarova is offline
Registered User
GenesisConnect
Genesis Member
Pro Plus Member
 
Join Date: Jan 2009
Location: Royal Oak, MI
Posts: 134
Default Lifestyle : Classic Theme - home.php Query

I am not sure how to update some php for the Classic Lifestyle theme. I am updating a site that has the WP_Querys in the php code. Below is the code for one of the calls to action. The problem I am having is that it is using the category id from the entry above to get some information. What I would like to find out is there another place in the code below that I have to put the Category ID, so it recognizes this one. I hope this makes sense. Thanks for your time. The part marked in RED is calling on a different category not the one I need.

<div class="hpbottom">
<h3>Fort Myers Area Community News</h3>

<?php $recent = new WP_Query("showposts=4&cat=11"); 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); ?>&amp;h=<?php echo get_theme_mod('featured_bottom_thumb_height'); ?>&amp;w=<?php echo get_theme_mod('featured_bottom_thumb_width'); ?>&amp;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_content_limit(350, __("[Read more of this review]", 'studiopress')); ?>

<hr/>

<?php endwhile; ?>

<?php if(get_theme_mod('featured_bottom')) : ?>
<strong><a href="<?php echo get_category_link(get_theme_mod('featured_bottom') ); ?>" rel="bookmark"><?php _e("Read more posts from ", 'studiopress'); echo get_cat_name(get_theme_mod('featured_bottom')); ?></a></strong>
<?php endif; ?>

</div>
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
lifestyle classic theme home page divadi General Discussion 1 05-26-2010 10:26 PM
Lifestyle Theme Classic and Genesis griverss99 General Discussion 2 05-02-2010 11:38 AM


All times are GMT -5. The time now is 04:48 PM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.