WordPress.org

Support

Support » How-To and Troubleshooting » posts in pages

posts in pages

  • mlke
    Member

    @mlke

    tried searching, couldn’t find anything…

    i want to display the posts for a category in a certain part of a created page.

Viewing 4 replies - 1 through 4 (of 4 total)
  • KatGirl
    Member

    @katgirl

    You didn’t look hard enough 🙂

    http://codex.wordpress.org/Template_Tags/query_posts

    Common uses might be to:
    * Display only a single post or page on your homepage.
    * Show all posts from a particular time period.
    * Show the latest post (only) on the front page.
    * Change how posts are ordered.
    * Show posts from only one category.

    mlke
    Member

    @mlke

    can’t seem to get it to work,

    i created the pages in the admin panel. i added the php code

    <?php query_posts(‘cat=1’); ?>

    nothing happens….

    is this wrong?

    moshu
    Member

    @moshu

    Yes, completely wrong.
    No code works if added to the content.
    You should create your own Page Template for it (see the Codex) and add the code to the template file. Then create a new Page using that template.

    mlke
    Member

    @mlke

    thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘posts in pages’ is closed to new replies.