WordPress.org

Ready to get started?Download WordPress

Forums

Adding read more link (6 posts)

  1. prathamesh
    Member
    Posted 2 years ago #

    I am using elbee-elgee theme i want to Modiy the theloop.php file so that the postinfo is displayed on another as whole post like read more link
    I have tried everything even changing the content with the excerpt and having the function function.php file my requirement is to get read more link without putting the more tag manually in the post i am posting the code here

    <?php
    	/* Start The Loop */ if (have_posts()) { while (have_posts()) { the_post(); ?>
    		<?php /* Permalink navigation has to be inside the loop */ if (is_single()) get_template_part('navigation'); ?>
    		<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    			<?php lblg_before_post_title(); ?>
    			<?php if( !is_single() && !is_page() ) { ?><h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php echo strip_tags(get_the_title()) ?>"><?php the_title(); ?></a></h2>
    			<?php } else { ?><h1><?php the_title(); ?></h1><?php } ?>
    
    			<?php lblg_before_itemtext(); ?>
    			<div class="itemtext">
    				<?php
    				if ( is_archive() or is_search() or is_tag() ) {
    					the_excerpt();
    				} else {
    
    						the_excerpt();
    				}
    				wp_link_pages( array( 'before' => '<div class="post-pagination">Pages: ', 'after' => '</div>', 'next_or_number' => 'number'));
    				?>
    			</div>
    			<?php lblg_after_itemtext(); ?>
    			<!--
    				<?php trackback_rdf(); ?>
    			-->
    		</div>
    	<?php } /* End while */?>
    	<?php if(is_home() || is_archive()) get_template_part('navigation'); ?>
    	<?php } /*End loop*/ ?>

    Thank you in advance

  2. keesiemeijer
    moderator
    Posted 2 years ago #

  3. prathamesh
    Member
    Posted 2 years ago #

    Like i said i have tried that also still not working

  4. vjpo
    Member
    Posted 2 years ago #

    No, you haven't. The code that you posted in your previous topic is wrong :zzz

  5. brightonmike
    Member
    Posted 2 years ago #

    You can just do it manually using the permalink within the loop.

  6. prathamesh
    Member
    Posted 2 years ago #

    can u give the code???
    @brightonmike

Topic Closed

This topic has been closed to new replies.

About this Topic