WP_Comment_Query Generator
Build a WP_Comment_Query or get_comments() call: status, type, post, author, date window, ordering and the fields you need.
get_comments( array( 'status' => 'approve' ) );WP_Comment_Query →WP_Query without the guesswork: build the arguments, see the query it produces, and get the loop that goes with it.
Build a WP_Comment_Query or get_comments() call: status, type, post, author, date window, ordering and the fields you need.
get_comments( array( 'status' => 'approve' ) );WP_Comment_Query →Build a WordPress date_query: before, after, between, a relative window or a specific year and month, on the column and timezone you mean.
'date_query' => array( array( 'after' => '30 days ago' ) )WP_Query →Build a WordPress meta_query array: clauses, comparison operators, value types and the relation between them, ready to drop into WP_Query.
'meta_query' => array( array( 'key' => 'price' ) )WP_Query →get_networks() arguments, with the honest note that almost every install has one network and the query is only worth writing on a multi-network setup.
Usually returns exactly one rowWP_Network_Query →Build WP_Query arguments with post type, ordering, taxonomy and meta conditions, dates and pagination, then copy the loop.
$query = new WP_Query( $args );class-wp-query.php →get_sites() arguments with the spam, deleted and archived flags set explicitly, because their default is null and null means either.
The defaults include spam and deletedWP_Site_Query →Build a WordPress tax_query array: taxonomies, term fields, operators, child term handling and the relation between clauses, ready for WP_Query.
'tax_query' => array( array( 'taxonomy' => 'genre' ) )WP_Query →Build a WP_Term_Query or get_terms() call: taxonomy, hierarchy, empty terms, ordering, meta conditions and the fields you actually need.
get_terms( array( 'taxonomy' => 'category' ) );WP_Term_Query →Build a WP_User_Query: roles, capabilities, search, meta conditions, ordering and the fields to select, without loading every user on the site.
new WP_User_Query( array( 'role' => 'author' ) );WP_User_Query →Generate valid, ready-to-paste WordPress code in seconds without configuring a local runtime.
Your input is never uploaded
No submit button, no waiting
Copy, download or share a link
Built by Pixarlabs for WordPress
Clean output that follows WordPress conventions, no bloat, and everything computed in your browser.
Tools run in your browser. Database names, prefixes and secret salts you type are never sent to a server.
$ uploaded: 0 bytesGenerated code uses translatable labels, safely quoted values and the core hooks WordPress expects.
$ add_action( 'init', 'register_book' );Copy the result, download a ready file, or share a link that restores your settings.
$ download wp-config.php