• Resolved bodjiang

    (@bodjiang)


    Hi all,

    I have create page template “news.php”, with template name “news”. To display basically all the posts I have.

    The posts on this page doesn’t show my custom “read more” link, also shows the full post rather than excerpt,(I had insert the “read-more” quick tag for each post). where the archive and category page shows them fine.

    Heres are my template structure:

    home.php
    index.php
    page.php
    single.php
    news.php (custom template)

    Here are the code for my index.php loop

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    
            <!-- begin post -->
            <div class="blogPost">
              div class="date"><?php the_time('M') ?><br /><span><?php the_time('j') ?></span></div>
    	    <h1><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h1>
    	   <div class="meta">
    	    By <span class="author"><?php the_author_link(); ?></span>  //   <?php the_category(', ') ?>   //   <?php comments_popup_link('No Comments', '1 Comment ', '% Comments'); ?>
    		 </div>
    	 <?php the_content(__('read more')); ?>
    	</div>

    Here are my news template loop:

    <?php query_posts('');
    		if (have_posts()) : while (have_posts()) : the_post(); ?>
    
            <!-- begin post -->
            <div class="blogPost">
                <div class="date"><?php the_time('M') ?><br /><span><?php the_time('j') ?></span></div>
    	       <h1><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h1>
    	     <div class="meta">
    		By <span class="author"><?php the_author_link(); ?></span>  //   <?php the_category(', ') ?>   //   <?php comments_popup_link('No Comments', '1 Comment ', '% Comments'); ?>
    	</div>
    	<?php the_content(); ?>
    </div>

    I was hoping someone can help me here.

    Many thanks

Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘More Link Missing on Custom Page template’ is closed to new replies.