[Plugin: WordPress Loop] custom_query_args documentation? (5 posts)

  1. allancole
    Posted 6 years ago #

    I’m trying to display a page using the WordPress Loop plugin widget.

    I have the post_type set to "PAGE" and I’m attempting to add my own parameters and select a page using the page_iD, query_posts parameter and the custom_query_arg option.

    I’ve tried both
    'page_id' => 23
    but neither seems to work. I’ve tried a few other query arguments, but none of them seem to work either.

    Am I doing this correctly?
    Is there any documentation that shows how the custom_query_arg option should be used?

  2. MichaelH
    Posted 6 years ago #

    I believe there might be a bug in the wordpress-loop.php script. If I'm reading it right then line 135 of that script:

    $args[] = wp_parse_args( $custom_args, $args );

    should be:

    $args = wp_parse_args( $custom_args, $args );

    And since Ptah has a comment in the script that says:

    //add custom query args, overrides anything, even the world!

    then your custom_query_args would be something like this:

  3. Pirate Dunbar
    Posted 6 years ago #

    page_id=23 works for me. Make sure that page id is valid. And are you using the latest WP Loop version?

    For the record, custom_query_args works like this:

  4. roburdick
    Posted 6 years ago #


    I love this plug-in! Does anyone know if there might be a way of avoiding duplicate posts. I want to use a loop in my sidebar widget area next to a single page post, and would like to not repeat the post that's in the main single post area.


  5. thibotus01
    Posted 6 years ago #

    Doesn't work for me either...

Topic Closed

This topic has been closed to new replies.

About this Topic