Changeset 30725
- Timestamp:
- 12/03/2014 10:30:55 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/post.php
r30723 r30725 4393 4393 * Optional. Array or string of arguments to retrieve pages. 4394 4394 * 4395 * @type int $child_of Page ID to return child and grandchild pages of. Default 0, or no restriction. 4396 * @type string $sort_order How to sort retrieved pages. 4397 * Default 'ASC'. Accepts 'ASC', 'DESC'. 4398 * @type string $sort_column What columns to sort pages by, comma-separated. 4399 * Default 'post_title'. Accepts 'post_author', 'post_date', 'post_title', 'post_name', 4400 * 'post_modified', 'post_modified_gmt', 'menu_order', 'post_parent', 'ID', 'rand', 4401 * 'comment_count'. 'post_' can be omitted for any values that start with it. 4402 * @type bool $hierarchical Whether to return pages hierarchically. Default true. 4403 * @type array $exclude Array of page IDs to exclude. 4404 * @type array $include Array of page IDs to include. Cannot be used with 'child_of', 'parent', 'exclude', 4405 * 'meta_key', 'meta_value', or 'hierarchical'. 4406 * @type string $meta_key Only include pages with this meta key. 4407 * @type string $meta_value Only include pages with this meta value. 4408 * @type string $authors A comma-separated list of author IDs. 4409 * @type int $parent Page ID to return direct children of. 'hierarchical' must be false. 4410 * Default -1, or no restriction. 4411 * @type int $exclude_tree Remove all children of the given ID from returned pages. 4412 * @type int $number The number of pages to return. Default 0, or all pages. 4413 * @type int $offset The number of pages to skip before returning. Requires 'number'. 4414 * Default 0. 4415 * @type string $post_type The post type to query. 4416 * Default 'page'. 4417 * @type string $post_status A comma-separated list of post status types to include. 4418 * Default 'publish'. 4395 * @type int $child_of Page ID to return child and grandchild pages of. 4396 * Default 0, or no restriction. 4397 * @type string $sort_order How to sort retrieved pages. Accepts 'ASC', 'DESC'. Default 'ASC'. 4398 * @type string $sort_column What columns to sort pages by, comma-separated. Accepts 'post_author', 4399 * 'post_date', 'post_title', 'post_name', 'post_modified', 'menu_order', 4400 * 'post_modified_gmt', 'post_parent', 'ID', 'rand', 'comment_count'. 4401 * 'post_' can be omitted for any values that start with it. 4402 * Default 'post_title'. 4403 * @type bool $hierarchical Whether to return pages hierarchically. Default true. 4404 * @type array $exclude Array of page IDs to exclude. Default empty array. 4405 * @type array $include Array of page IDs to include. Cannot be used with `$child_of`, 4406 * `$parent`, `$exclude`, `$meta_key`, `$meta_value`, or `$hierarchical`. 4407 * Default empty array. 4408 * @type string $meta_key Only include pages with this meta key. Default empty. 4409 * @type string $meta_value Only include pages with this meta value. Requires `$meta_key`. 4410 * Default empty. 4411 * @type string $authors A comma-separated list of author IDs. Default empty. 4412 * @type int $parent Page ID to return direct children of. `$hierarchical` must be false. 4413 * Default -1, or no restriction. 4414 * @type string|array $exclude_tree Comma-separated string or array of page IDs to exclude. 4415 * Default empty array. 4416 * @type int $number The number of pages to return. Default 0, or all pages. 4417 * @type int $offset The number of pages to skip before returning. Requires `$number`. 4418 * Default 0. 4419 * @type string $post_type The post type to query. Default 'page'. 4420 * @type string $post_status A comma-separated list of post status types to include. 4421 * Default 'publish'. 4419 4422 * } 4420 * @return array List of pages matching defaults or $args.4423 * @return array List of pages matching defaults or `$args`. 4421 4424 */ 4422 4425 function get_pages( $args = array() ) {
Note: See TracChangeset
for help on using the changeset viewer.