Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 90212

"wp-query" ambiguously refers to one of two things. 1) WP_Query is a class native to WordPress which allows users to query the posts database using a number of criteria. 2) $wp_query is the global variable that holds the main query object prepared by WordPress based on a given request.

8 votes

Exclude a category from WP_Query

https://codex.wordpress.org/Class_Reference/WP_Query category__not_in (array) - use category id. $argsQuery = array( 'posts_per_page' => 3, 'post_type' => 'download', 'category …
Joe's user avatar
  • 91
0 votes

How to set a custom post type to have viewable future posts

Without change the post status you can display future posts single and archive with pre_get_posts too: add_action( 'pre_get_posts', 'joesz_include_future_posts' ); function joesz_include_future_posts …
Joe's user avatar
  • 91