Displaying Common Information using common functions in wordpress?

Picture of Woocoders
Woocoders
2nd September 2020

Now let’s move on to some more functions we can use inside the loop. Many of these functions can only be used inside the loop and may not work if used outside of it.

Display the title of the post:

<?php the_title(); ?>

Display the URL of the post:

<?php the_permalink(); ?>

Display the content of the post:

<?php the_content(); ?>

Display the excerpt of the post:

<?php the_excerpt(); ?>

Display the category of the post:

<?php the_category(); ?>

Display the tags used in the post:

<?php the_tags(); ?>

Display the time the post was published (uses PHP date formatting as a parameter):

<?php the_time(); ?>

Share this post: