WP_QueryThe WordPress Query class.
Located in /ptests/samples/omitted/query.php (line 822)
int
$comment
(line 968)
Current comment ID.
array
$comments
(line 941)
The list of comments for current post.
int
$comment_count
= 0 (line 950)
The amount of comments for the posts.
int
$current_comment
= -1 (line 959)
The index of the comment in the comment loop.
int
$current_post
= -1 (line 914)
Index of the current item in the loop.
int
$found_posts
= 0 (line 977)
Amount of posts if limit clause was not used.
bool
$in_the_loop
= false (line 923)
Whether the loop has started and the caller is in the loop.
bool
$is_404
= false (line 1166)
Set if query couldn't found anything.
bool
$is_admin
= false (line 1193)
Set if query is part of administration page.
bool
$is_archive
= false (line 1031)
Set if query is an archive list.
bool
$is_attachment
= false (line 1202)
Set if query is an attachment.
bool
$is_author
= false (line 1085)
Set if query contains an author.
bool
$is_category
= false (line 1094)
Set if query contains category.
bool
$is_comments_popup
= false (line 1175)
Set if query is within comments popup window.
bool
$is_comment_feed
= false (line 1139)
Set if query is comment feed display.
bool
$is_date
= false (line 1040)
Set if query is part of a date.
bool
$is_day
= false (line 1067)
Set if query contains a day.
bool
$is_feed
= false (line 1130)
Set if query is feed display.
bool
$is_home
= false (line 1157)
Set if query is blog homepage.
bool
$is_month
= false (line 1058)
Set if query contains a month.
bool
$is_page
= false (line 1022)
Set if query returns a page.
bool
$is_paged
= false (line 1184)
Set if query is paged
bool
$is_posts_page
= false (line 1231)
Set if query contains posts.
Basically, the homepage if the option isn't set for the static homepage.
bool
$is_post_type_archive
= false (line 1240)
Set if query is for a post type archive.
bool
$is_preview
= false (line 1013)
Set if query is preview of blog.
bool
$is_robots
= false (line 1220)
Set if query is for robots.
bool
$is_search
= false (line 1121)
Set if query was part of a search result.
bool
$is_single
= false (line 1004)
Set if query is single post.
bool
$is_singular
= false (line 1211)
Set if is single, is a page, or is an attachment.
bool
$is_tag
= false (line 1103)
Set if query contains tag.
bool
$is_tax
= false (line 1112)
Set if query contains taxonomy.
bool
$is_time
= false (line 1076)
Set if query contains time.
bool
$is_trackback
= false (line 1148)
Set if query is trackback.
bool
$is_year
= false (line 1049)
Set if query contains a year.
int
$max_num_comment_pages
= 0 (line 995)
The amount of comment pages.
int
$max_num_pages
= 0 (line 986)
The amount of pages.
object WP_Meta_Query
$meta_query
= false (line 858)
Metadata query container
object
$post
(line 932)
The current post ID.
array
$posts
(line 896)
List of posts.
int
$post_count
= 0 (line 905)
The amount of posts for the current query.
object|array
$queried_object
(line 869)
Holds the data for a single object that is queried.
Holds the contents of a post, page, category, attachment.
int
$queried_object_id
(line 878)
The ID of the queried object.
array
$query
(line 831)
Query vars set by the user
array
$query_vars
= array() (line 840)
Query vars, after parsing
string
$request
(line 887)
Get post database query.
object WP_Tax_Query
$tax_query
(line 849)
Taxonomy query, as passed to get_tax_sql()
bool
$thumbnails_cached
= false (line 1267)
Set if post thumbnails are cached
Constructor __construct (line 2989)
Constructor.
Sets up the WordPress query, if parameter is not empty.
fill_query_vars (line 1354)
Fills in the query variables, which do not exist within the parameter.
get (line 1874)
Retrieve query variable.
get_posts (line 1906)
Retrieve the posts based on query variables.
There are a few filters and actions that can be used to modify the post database query.
get_queried_object (line 2919)
Retrieve queried object.
If queried object is not set, then the queried object will be set from the category, tag, taxonomy, posts page, single post, page, or author query variable. After it is set up, it will be returned.
get_queried_object_id (line 2968)
Retrieve ID of the current queried object.
have_comments (line 2869)
Whether there are more comments available.
Automatically rewinds comments when finished.
have_posts (line 2800)
Whether there are more posts available in the loop.
Calls action 'loop_end', when the loop is complete.
init (line 1313)
Initiates object properties and sets default values.
is_404 (line 3467)
Is the query a 404 (returns no results)?
is_archive (line 3004)
Is the query for an archive page?
Month, Year, Category, Author, Post Type archive...
is_attachment (line 3032)
Is the query for an attachment page?
is_author (line 3047)
Is the query for an author archive page?
If the $author parameter is specified, this function will additionally check if the query is for one of the authors specified.
is_category (line 3079)
Is the query for a category archive page?
If the $category parameter is specified, this function will additionally check if the query is for one of the categories specified.
is_comments_popup (line 3174)
Whether the current URL is within the comments popup window.
is_comment_feed (line 3225)
Is the query for a comments feed?
is_date (line 3185)
Is the query for a date archive?
is_day (line 3197)
Is the query for a day archive?
is_feed (line 3209)
Is the query for a feed?
is_front_page (line 3247)
Is the query for the front page of the site?
This is for what is displayed at your site's main URL.
Depends on the site's "Front page displays" Reading Settings 'show_on_front' and 'page_on_front'.
If you set a static page for the front page of your site, this function will return true when viewing that page.
Otherwise the same as @see WP_Query::is_home()
is_home (line 3273)
Is the query for the blog homepage?
This is the page which shows the time based blog content of your site.
Depends on the site's "Front page displays" Reading Settings 'show_on_front' and 'page_for_posts'.
If you set a static page for the front page of your site, this function will return true only on the page you set as the "Posts page".
is_month (line 3284)
Is the query for a month archive?
is_page (line 3302)
Is the query for a single page?
If the $page parameter is specified, this function will additionally check if the query is for one of the pages specified.
is_paged (line 3330)
Is the query for paged result and not for the first page?
is_post_type_archive (line 3016)
Is the query for a post type archive page?
is_preview (line 3341)
Is the query for a post or page preview?
is_robots (line 3352)
Is the query for the robots file?
is_search (line 3363)
Is the query for a search?
is_single (line 3383)
Is the query for a single post?
Works for any post type, except attachments and pages
If the $post parameter is specified, this function will additionally check if the query is for one of the Posts specified.
is_singular (line 3418)
Is the query for a single post of any post type (post, attachment, page, ... )?
If the $post_types parameter is specified, this function will additionally check if the query is for one of the Posts Types specified.
is_tag (line 3111)
Is the query for a tag archive page?
If the $tag parameter is specified, this function will additionally check if the query is for one of the tags specified.
is_tax (line 3144)
Is the query for a taxonomy archive page?
If the $taxonomy parameter is specified, this function will additionally check if the query is for that specific $taxonomy.
If the $term parameter is specified in addition to the $taxonomy parameter, this function will additionally check if the query is for one of the terms specified.
is_time (line 3434)
Is the query for a specific time?
is_trackback (line 3445)
Is the query for a trackback endpoint call?
is_year (line 3456)
Is the query for a specific year?
next_comment (line 2834)
Iterate current comment index and return comment object.
next_post (line 2759)
Set up the next post and iterate current post index.
parse_query (line 1415)
Parse a query string and set query type booleans.
parse_query_vars (line 1341)
Reparse the query vars.
parse_tax_query (line 1674)
query (line 2901)
Sets up the WordPress query by parsing query string.
rewind_comments (line 2885)
Rewind the comments, resets the comment index and comment to first.
rewind_posts (line 2819)
Rewind the posts and reset post index.
set (line 1890)
Set query variable.
set_404 (line 1856)
Sets the 404 property and saves whether query is feed.
the_comment (line 2849)
Sets up the current comment.
the_post (line 2778)
Sets up the current post.
Retrieves the next post, sets up the post, sets the 'in the loop' property to true.
Documentation generated on Thu, 29 Sep 2011 01:44:46 +0530 by phpDocumentor 1.4.3