WordPress archive – customizing the archive output

Users of wordpress often organize menus on the site through Categories. In this case the categories are displayed as an archive – without formatting, without pictures, videos, etc.

 

Task: show images, videos and formatting when categories are displayed.

 

Solution:

1) For older versions of WordPress

Find the following line in the archive.php template file:

<?php the_excerpt(); ?>

And replace it with:

<?php the_content(); ?>

 

 

2) For new versions of WordPress (including templates family Twenty Ten and others).

 

In the file loop.php find the line:

<?php if ( is_archive() || is_search() ) : // Only display excerpts for archives and search. ?>

Change it to:

<?php if ( is_search() ) : // Only display excerpts for search. ?>

 

 

Warning! Don’t forget to replace all occurring values (there are usually two).