WordPress.org

Ready to get started?Download WordPress

Forums

Archivist - Custom Archive Templates
How to display certain posts by post ID ? (4 posts)

  1. spabav
    Member
    Posted 1 year ago #

    I am trying despretely to find a way to display certain posts ( via ID) with the archivist plugin.

    Is there a way to do it?

    Something like:

    [archivist post="35,77,128"] - with 35 ,77 and 128 being the post id.

    I tried multiple ways but cant find the right syntax.

    Please help. Anybody?

    http://wordpress.org/extend/plugins/archivist-custom-archive-templates/

  2. eteubert
    Member
    Plugin Author

    Posted 1 year ago #

    try [archivist query="post__in=1,2,3"]

  3. spabav
    Member
    Posted 1 year ago #

    Hi Eric,
    Thanks for fast reply, but your suggestion does not work.

    if i do:
    [archivist query="post__in=1,2,3"]
    i get:
    Warning: array_map() [function.array-map]: Argument #2 should be an array in...ml/wp-includes/query.php on line 2164

    I saw that you had two underscores (in post__in) in the syntax, so i tried:
    [archivist query="post_in=1"]
    with 1 being my post id... and it did not work either.
    Displays ALL posts.

    Any idea how this could work?

  4. eteubert
    Member
    Plugin Author

    Posted 1 year ago #

    In this case it's probably not possible. As a workaround, put all the posts you want into the same category and use the normal shortcode [archivist category="mycategory"].

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.