WordPress.org

Forums

Category Listings Summary Lengths (13 posts)

  1. TonyWright
    Member
    Posted 9 years ago #

    Hey there. I run http://www.rapnews.co.uk and have a quick question.

    I just want to know if there's anywhere to simply increase the number of words to a post's summary on the category archieve pages?

    At the moment the lines for each post are about 15 words. It'd be great to double this, or in fact set some code somewhere so that the whole 'optional excerpt' is displayed.

    As it stands, the summary is a waste of space because it's not long enough to provide a good enough description for each post listed.

    Best,

    Tee.

  2. Chris_K
    Member
    Posted 9 years ago #

    That summary seems a bit short to have been generated via the_excerpt() but if it is, this plugin will let you set things longer: http://guff.szub.net/2005/02/26/the-excerpt-reloaded/

  3. TonyWright
    Member
    Posted 9 years ago #

    Thanks. It seems that I already have the excerpt reloaded plugin activated.

    But it looks like the plugin only determines the length of a post summary on the archieve, if the post doesn't have an excerpt. Almost all of mine do. I increased the value in the plugin file and it had no effect.

    Best,

    Tee.

  4. TonyWright
    Member
    Posted 9 years ago #

    Any other ideas please?

    Thanks

  5. Chris_K
    Member
    Posted 9 years ago #

    Not sure what to suggest. A look at the code might be useful at this point... would you be willing to put your archive.php code at one of the pastebin type services and post a link back here to it?

  6. moshu
    Member
    Posted 9 years ago #

    The excerpt reloaded does have an option to define the length of the excerpt!

  7. ryoken
    Member
    Posted 9 years ago #

    are you actually using the plugin in your archives file? may seem obvious, but a good thing to check.

  8. TonyWright
    Member
    Posted 9 years ago #

    Woops! How silly of me! Doesn't seem like the plugin is mentioned in the archieve.php at all. Any suggestions on what I need to write, and where:

    <?php
    /*
    Template Name: Archives
    */
    ?>

    <?php get_header(); ?>

    <div id="content" class="widecolumn">

    <?php include (TEMPLATEPATH . '/searchform.php'); ?>

    <h2>Archives by Month:</h2>

    <ul>
    <?php wp_get_archives('type=monthly'); ?>
    </ul>
    <h2>Archives by Subject:</h2>

    <ul>
    <?php wp_list_cats(); ?>
    </ul>
    </div>

    <?php get_footer(); ?>

  9. moshu
    Member
    Posted 9 years ago #

    Tony, you are mixing two things!
    The code you posted here is supposed to be in the archives.php - notice the S at the end!

    Meanwhile, the monthly and category archive listings are displayed by the archive.php template file (no plural S at the end!).

  10. TonyWright
    Member
    Posted 9 years ago #


  11. TonyWright
    Member
    Posted 9 years ago #

    Silly me. I've realised there to be two .php's now and have noticed the reloaded reference in the code and managed to increase the length of the arcieve summary myself. I just have a few more questions:

    Is it possible for the archieve to show a length defined summary for one category, and not others? I'd like summaries of all my Rapnews.co.uk interviews, whereas I'd prefer the archieve list of news/videos/reviews to just be the title of the post, with no gaps inbetween each.

    Thanks!

  12. moshu
    Member
    Posted 9 years ago #

    Well, it is possible.
    You either make category templates for them:
    http://codex.wordpress.org/Category_Templates
    or you can use conditionals in the same one file:
    http://codex.wordpress.org/Conditional_Tags

  13. TonyWright
    Member
    Posted 9 years ago #

    I guess making conditions would be the easiest for a dumb person such as me? Wish me luck!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.