• Resolved victorialaceellis

    (@victorialaceellis)


    What do I need to change in the CSS form to have my posts show the whole post instead of the “excerpt” that leads to read more? I want the whole post on all the pages.

Viewing 1 replies (of 1 total)
  • Hi victorialaceellis

    To show whole post instead of the excerpt and remove Read More button you need to create and customize Child Theme.
    After creating child theme copy and paste index.php file from main theme’s folder to child theme’s folder.
    Now copy and paste below code in index.php file in child theme.

    <!-- Blog post -->
                    <div <?php post_class('blog-posts'); ?> id="post-<?php the_ID(); ?>">
                        <div class="col-lg-8 col-lg-offset-2">
                            <div class="post wow fadeIn" data-wow-duration="2s">
                                <h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
                                <ul class="list-inline">
                                    <li><?php _e( 'Post By:', 'rokophotolite' ); ?> <?php the_author_posts_link(); ?></li>
                                    <li><?php _e( 'Date:', 'rokophotolite' ); ?> <time><?php the_time( get_option( 'date_format' ) ); ?></time></li>
                                    <li><?php _e( 'Category:', 'rokophotolite' ); ?> <?php the_category(', '); ?></li>
                                </ul>
                                <?php if ( has_post_thumbnail() && ! post_password_required() ) : ?>
                                    <?php
                                        $image_id = get_post_thumbnail_id();
                                        $image_url_mobile = wp_get_attachment_image_src($image_id, 'blog_post_thumbnail_mobile', true);
                                    ?>
                                    <picture>
                                        <source media="(max-width: 480px)" srcset="<?php echo esc_url( $image_url_mobile[0] ); ?>">
                                        <?php the_post_thumbnail( 'blog_post_thumbnail', array( 'class' => "img-responsive")); ?>
                                    </picture>
                                <?php endif; ?>
                                <?php the_content(); ?>
    
                            </div>
                        </div>
                        <div class="clearfix"></div>
                        <div class="divider"></div>
                    </div>

    Now you need to activate child theme.
    Note: Please customize files of child theme, so your changes will not overwrite on theme update.
    Hope this will solve your issue.

    Best Regards!!!

Viewing 1 replies (of 1 total)
  • The topic ‘FULL POST INSTEAD OF EXCERPT’ is closed to new replies.