Show categories posts? (4 posts)

  1. Jaqueline
    Posted 11 years ago #

    I was very happy using Show Category Posts plugin, but it doesn't work on WP 1.5.
    When I add the command:

    <?php echo show_category_posts('category=8&scp_limit=5&scp_status=publish&sort_order=DESC&sort_field=post_date'); ?><?php if ($scp_posts) : foreach ($scp_posts as $post) : start_wp(); ?>

    It gives me a parse error: Parse error: parse error, unexpected $ in...

    I installed 1.5 on a new website, just to try it, and I use Show Categories, to make my blog look like a "Journal", with a bunch of sections on the first page, each one showing a certain Category. Am I missing something in 1.5 that will work like that without the plugin?

    Thanks a lot!!

  2. Jaqueline
    Posted 11 years ago #

    plzzzzzzz? ;)

  3. Kafkaesqui

    Posted 11 years ago #

    Show Categories will not work with 1.5, so there's not much you can do to get past the error. Kitten chose not to upgrade Show Categories because of functionality in 1.5 that duplicates it. You should be able to use this for what you're attempting to do:

    <?php query_posts("category_name=CATNAME&orderby=post_date&order=
    DESC&showposts=5"); ?>
    <?php while (have_posts()) : the_post(); ?>

    ~Your post template tags here~

    <?php endwhile; ?>

    Replace CATNAME with the "nicename" of the category.

  4. Jaqueline
    Posted 11 years ago #

    Yes, I tried to check ou the query_posts, but I couldn´t find it. That´s perfect for me! It makes my first page a little bit slowly, but I really don´t care! rs

    Thanks a lot!! It was exactly what I was looking for! ;)

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.