Categories: wordpress

EXCERPT SIMPLIFIED IN WORDPRESS THEME DEVELOPMENT

Excerpt is the short form of the whole article. If you want to get the whole article inside the loop you need to echo the tag get_the_content(), but to get short form or the article you can do two method.

FIRST AND EASY METHOD
you can simply echo get_the_excerpt();

SECOND METHOD BUT FLEXIBLE METHOD
you can abridge as much words as you like in this method. The syntax is as follow
$article_data = strip_tags(substr(get_the_content(), 0, 500));
echo $article_data.’ ….’;

jaminrai

Recent Posts

The Duck and the Tortoise: A Tale of Patience and Teamwork

In a serene forest by the edge of a sparkling lake, there lived a cheerful…

2 weeks ago

10 Smart Strategies for a Secure and Enjoyable Retirement

Retiring comfortably is a goal many aspire to achieve, and with the right strategies, it’s…

2 weeks ago

Troubleshooting a Slow Computer

Is your computer running frustratingly slow? Don't worry; you're not alone in facing this common…

2 weeks ago

The Clever Fox and the Greedy Crow

Once, in a sunny forest, Fox and Crow were friends. One day, Crow found a…

2 weeks ago

The Little Lantern and the Lost Stars

Once upon a time, in a cozy village nestled between rolling hills and whispering forests,…

2 weeks ago