Support » Fixing WordPress » Separate category on page using excerpt

  • Desislava Shtebetovska


    I just want to thank the author of this post and share how I changed it for my site.
    First I created a blank page template.
    I changed the code to the author of the above link in the following way using the_excerpt:

    Template Name: zakoni-imoti
    <?php get_header(); ?>  
    <?php // your loop here ?>
    <div id="main">
    <?php query_posts('cat=267');?>
    <?php while (have_posts()) : the_post(); ?>
    <?php if (function_exists('get_cat_icon')) get_cat_icon(); ?><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( '', 'lagom' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a>
    <?php the_date('F Y'); ?>
    <?php the_excerpt();?>
    <footer class="entry-meta">
    		<span class="cat-links"><span class="entry-utility-prep entry-utility-prep-cat-links"><?php _e( 'Публикувано в: ', 'lagom' ); ?></span><?php the_category( ', ' ); ?></span>
    		<span class="sep">  </span>
    		<?php the_tags( '<span class="tag-links">' . __( 'Етикети:', 'lagom' ) . '</span>', ', ', '<span class="sep" </span>' ); ?>
    </footer><!-- #entry-meta --><hr/>
    <?php endwhile; ?>
    <?php get_footer(); ?>

    Look what I mean here in my sait.
    Thank you so much for everything that all you share here!

  • The topic ‘Separate category on page using excerpt’ is closed to new replies.