Clarify that conditional tags only return true for existing objects, not 404 situations. props SergeyBiryukov, fixes #16312.
git-svn-id: http://core.svn.wordpress.org/trunk@21890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
96d002c4dd
commit
095bc8b482
|
@ -128,7 +128,7 @@ function wp_reset_postdata() {
|
|||
*/
|
||||
|
||||
/**
|
||||
* Is the query for an archive page?
|
||||
* Is the query for an existing archive page?
|
||||
*
|
||||
* Month, Year, Category, Author, Post Type archive...
|
||||
*
|
||||
|
@ -150,7 +150,7 @@ function is_archive() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a post type archive page?
|
||||
* Is the query for an existing post type archive page?
|
||||
*
|
||||
* @see WP_Query::is_post_type_archive()
|
||||
* @since 3.1.0
|
||||
|
@ -171,7 +171,7 @@ function is_post_type_archive( $post_types = '' ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for an attachment page?
|
||||
* Is the query for an existing attachment page?
|
||||
*
|
||||
* @see WP_Query::is_attachment()
|
||||
* @since 2.0.0
|
||||
|
@ -191,7 +191,7 @@ function is_attachment() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for an author archive page?
|
||||
* Is the query for an existing author archive page?
|
||||
*
|
||||
* If the $author parameter is specified, this function will additionally
|
||||
* check if the query is for one of the authors specified.
|
||||
|
@ -215,7 +215,7 @@ function is_author( $author = '' ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a category archive page?
|
||||
* Is the query for an existing category archive page?
|
||||
*
|
||||
* If the $category parameter is specified, this function will additionally
|
||||
* check if the query is for one of the categories specified.
|
||||
|
@ -239,7 +239,7 @@ function is_category( $category = '' ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a tag archive page?
|
||||
* Is the query for an existing tag archive page?
|
||||
*
|
||||
* If the $tag parameter is specified, this function will additionally
|
||||
* check if the query is for one of the tags specified.
|
||||
|
@ -263,7 +263,7 @@ function is_tag( $slug = '' ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a taxonomy archive page?
|
||||
* Is the query for an existing taxonomy archive page?
|
||||
*
|
||||
* If the $taxonomy parameter is specified, this function will additionally
|
||||
* check if the query is for that specific $taxonomy.
|
||||
|
@ -312,7 +312,7 @@ function is_comments_popup() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a date archive?
|
||||
* Is the query for an existing date archive?
|
||||
*
|
||||
* @see WP_Query::is_date()
|
||||
* @since 1.5.0
|
||||
|
@ -332,7 +332,7 @@ function is_date() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a day archive?
|
||||
* Is the query for an existing day archive?
|
||||
*
|
||||
* @see WP_Query::is_day()
|
||||
* @since 1.5.0
|
||||
|
@ -452,7 +452,7 @@ function is_home() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a month archive?
|
||||
* Is the query for an existing month archive?
|
||||
*
|
||||
* @see WP_Query::is_month()
|
||||
* @since 1.5.0
|
||||
|
@ -472,7 +472,7 @@ function is_month() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single page?
|
||||
* Is the query for an existing single page?
|
||||
*
|
||||
* If the $page parameter is specified, this function will additionally
|
||||
* check if the query is for one of the pages specified.
|
||||
|
@ -579,7 +579,7 @@ function is_search() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single post?
|
||||
* Is the query for an existing single post?
|
||||
*
|
||||
* Works for any post type, except attachments and pages
|
||||
*
|
||||
|
@ -608,7 +608,7 @@ function is_single( $post = '' ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single post of any post type (post, attachment, page, ... )?
|
||||
* Is the query for an existing 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.
|
||||
|
@ -675,7 +675,7 @@ function is_trackback() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a specific year?
|
||||
* Is the query for an existing year archive?
|
||||
*
|
||||
* @see WP_Query::is_year()
|
||||
* @since 1.5.0
|
||||
|
@ -3040,7 +3040,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for an archive page?
|
||||
* Is the query for an existing archive page?
|
||||
*
|
||||
* Month, Year, Category, Author, Post Type archive...
|
||||
*
|
||||
|
@ -3053,7 +3053,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a post type archive page?
|
||||
* Is the query for an existing post type archive page?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
@ -3070,7 +3070,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for an attachment page?
|
||||
* Is the query for an existing attachment page?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
@ -3081,7 +3081,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for an author archive page?
|
||||
* Is the query for an existing author archive page?
|
||||
*
|
||||
* If the $author parameter is specified, this function will additionally
|
||||
* check if the query is for one of the authors specified.
|
||||
|
@ -3113,7 +3113,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a category archive page?
|
||||
* Is the query for an existing category archive page?
|
||||
*
|
||||
* If the $category parameter is specified, this function will additionally
|
||||
* check if the query is for one of the categories specified.
|
||||
|
@ -3145,7 +3145,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a tag archive page?
|
||||
* Is the query for an existing tag archive page?
|
||||
*
|
||||
* If the $tag parameter is specified, this function will additionally
|
||||
* check if the query is for one of the tags specified.
|
||||
|
@ -3173,7 +3173,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a taxonomy archive page?
|
||||
* Is the query for an existing taxonomy archive page?
|
||||
*
|
||||
* If the $taxonomy parameter is specified, this function will additionally
|
||||
* check if the query is for that specific $taxonomy.
|
||||
|
@ -3228,7 +3228,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a date archive?
|
||||
* Is the query for an existing date archive?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
@ -3239,7 +3239,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a day archive?
|
||||
* Is the query for an existing day archive?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
@ -3326,7 +3326,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a month archive?
|
||||
* Is the query for an existing month archive?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
@ -3337,7 +3337,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single page?
|
||||
* Is the query for an existing single page?
|
||||
*
|
||||
* If the $page parameter is specified, this function will additionally
|
||||
* check if the query is for one of the pages specified.
|
||||
|
@ -3416,7 +3416,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single post?
|
||||
* Is the query for an existing single post?
|
||||
*
|
||||
* Works for any post type, except attachments and pages
|
||||
*
|
||||
|
@ -3453,7 +3453,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a single post of any post type (post, attachment, page, ... )?
|
||||
* Is the query for an existing 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.
|
||||
|
@ -3498,7 +3498,7 @@ class WP_Query {
|
|||
}
|
||||
|
||||
/**
|
||||
* Is the query for a specific year?
|
||||
* Is the query for an existing year archive?
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue