Exibir resumos no tema SilverOrchid
-
Desculpem o assunto, sei que já tem perguntas respondidas sobre isso mas eu já apiquei e dica de trocar o:
<?php the_content(); ?>
Por:
<?php the_excerpt(); ?>E mesmo assim minha página, neste tema, não exibe os resumos das categorias e sim o post completo….
Alguém pode me ajudar?O Código de cada categoria é:
<?php /** * Theme: silverOrchid * Theme URL: http://gazpo.com/2012/04/silverorchid * Created: April 2012 * Author: Sami Ch. * URL: http://gazpo.com * **/ $gazpo_settings = get_option( 'gazpo_options'); $cat1_id = $gazpo_settings['gazpo_feat_cat1']; $cat1_name = get_cat_name($cat1_id); $cat1_url = get_category_link( $cat1_id ); ?> <div class="feat-cat"> <h3 class="title"><a href="<?php echo esc_url( $cat1_url ); ?>" title="Category Name"><?php echo $cat1_name; ?></a></h3> <div class="category-content whitebg"> <div class="left"> <?php query_posts('cat='.$cat1_id.'&posts_per_page=1'); if (have_posts()) : while (have_posts()) : the_post(); //post thumbnail the_post_thumbnail( 'large' ); ?> <h3><a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a></h3> <div class="post-meta"> <span class="date"><?php the_time('F j'); ?></span> <span class="comments"><?php comments_popup_link( __('no comments', 'silverorchid'), __( '1 comment', 'silverorchid'), __('% comments', 'silverorchid')); ?></span> </div> <p> <?php $content = get_the_content(); $content = strip_tags($content); echo mb_substr($content, 0, 140). '...'; ?> </p> <?php endwhile; endif; wp_reset_query(); ?> </div> <div class="right"> <ul> <?php query_posts('cat='.$cat1_id.'&posts_per_page=3&offset=1'); if (have_posts()) : while (have_posts()) : the_post(); ?> <li> <div class="thumb"> <?php the_post_thumbnail( 'thumbnail' ); ?> </div> <div class="post-right"> <h5 class="title"> <a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"> <?php $short_title = mb_substr(the_title('','',FALSE),0,50); echo $short_title; if (strlen($short_title) >49){ echo '...'; } ?> </a> </h5> <div class="post-meta"> <span class="date"><?php the_time('F j'); ?></span> <span class="comments"><?php comments_popup_link( __('no comments', 'silverorchid'), __( '1 comment', 'silverorchid'), __('% comments', 'silverorchid')); ?></span> </div> <p> <?php $content = get_the_content(); $content = strip_tags($content); echo mb_substr($content, 0, 60). '...'; ?> </p> </div> </li> <?php endwhile; endif; wp_reset_query(); ?> </ul> </div> </div> </div>
Visualizando 2 respostas - 1 até 2 (de um total de 2)
Visualizando 2 respostas - 1 até 2 (de um total de 2)
- O tópico ‘Exibir resumos no tema SilverOrchid’ está fechado para novas respostas.