WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )apply_filters( "hook_name", "what_to_filter" ).Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
| Line | Code |
|---|---|
| 818 | $post_stati = array( // array( adj, noun ) |
| 819 | 'publish' => array(_x('Published', 'post'), __('Published posts'), _n_noop('Published <span class="count">(%s)</span>', 'Published <span class="count">(%s)</span>')), |
| 820 | 'future' => array(_x('Scheduled', 'post'), __('Scheduled posts'), _n_noop('Scheduled <span class="count">(%s)</span>', 'Scheduled <span class="count">(%s)</span>')), |
| 821 | 'pending' => array(_x('Pending Review', 'post'), __('Pending posts'), _n_noop('Pending Review <span class="count">(%s)</span>', 'Pending Review <span class="count">(%s)</span>')), |
| 822 | 'draft' => array(_x('Draft', 'post'), _x('Drafts', 'manage posts header'), _n_noop('Draft <span class="count">(%s)</span>', 'Drafts <span class="count">(%s)</span>')), |
| 823 | 'private' => array(_x('Private', 'post'), __('Private posts'), _n_noop('Private <span class="count">(%s)</span>', 'Private <span class="count">(%s)</span>')), |
| 824 | 'trash' => array(_x('Trash', 'post'), __('Trash posts'), _n_noop('Trash <span class="count">(%s)</span>', 'Trash <span class="count">(%s)</span>')), |
| 825 | ); |
| 826 | |
| 827 | $post_stati = apply_filters('post_stati', $post_stati); |
| 828 | |
| 829 | $avail_post_stati = get_available_post_statuses('post'); |
| 830 | |
| 831 | $post_status_q = ''; |
| 832 | if ( isset($q['post_status']) && in_array( $q['post_status'], array_keys($post_stati) ) ) { |
| 833 | $post_status_q = '&post_status=' . $q['post_status']; |
| 834 | $post_status_q .= '&perm=readable'; |
| 835 | } |
| 836 | |