0

I thought that by default when you loop content (like blog posts) in a WordPress the content is limited to 55 characters. I have not touched my functions.php file yet for when I loop the posts the article/ content is published in full.

My loop is like this - should the content tag be different?

<?php

if( have_posts() ):

    while( have_posts() ): the_post(); ?>

        <h3><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h3>
    <p>Posted on: <?php the_time('F j, Y'); ?> <?php the_category( ', ' ); ?></p>

        <p><?php the_content(); ?></p>

        <hr>

    <?php endwhile;

endif;

?> 

Thanks for all help.

1 Answer 1

0

No it's not. The length limit is for excerpt, which should be called manually. To get the excerpt in your loop, you should use:

<p><?php the_excerpt(); ?></p>

Instead of:

<p><?php the_content(); ?></p>

If you thought of this because of the option in the reading section of settings:

Excerpt for feeds

Then you have to notice, this is for RSS feeds, which can be accessed at:

www.example.com/feed

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.