Post summary on frontpage, summary bold in full story

Posted by Nick in Tech, Tricks on February 25th, 2008.

A trick that I used for this site. Always wondered how to get a post summary on the frontpage, but the same paragraph in bold in the full story? Well, that’s exactly what I was l asking myself back then. However, it’s very easy. Read along.

The basic idea is: Regular font weight on the front page: Same summary, but bold when you click on (more…): How do you get this done?

1. Open up index.php. Replace <?php the_content(); ?> by: <?php the_excerpt(); ?> <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">(more…)</a>.

2. Open up single.php. Find the Loop and before <?php the_content(); ?> line insert this: <strong> <?php the_excerpt(); ?></strong>.

3. You should type the summary in the "optional excerpt" field. This way you don’t have to manually split the text. That’s all!

Leave a Reply