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 |
---|---|
520 | $q['cat'] = (int) $q['cat']; |
521 | $post_stati = array( // array( adj, noun ) |
522 | 'publish' => array(__('Published'), __('Published posts'), __ngettext_noop('Published (%s)', 'Published (%s)')), |
523 | 'future' => array(__('Scheduled'), __('Scheduled posts'), __ngettext_noop('Scheduled (%s)', 'Scheduled (%s)')), |
524 | 'pending' => array(__('Pending Review'), __('Pending posts'), __ngettext_noop('Pending Review (%s)', 'Pending Review (%s)')), |
525 | 'draft' => array(__('Draft'), _c('Drafts|manage posts header'), __ngettext_noop('Draft (%s)', 'Drafts (%s)')), |
526 | 'private' => array(__('Private'), __('Private posts'), __ngettext_noop('Private (%s)', 'Private (%s)')), |
527 | ); |
528 |
|
529 | $post_stati = apply_filters('post_stati', $post_stati); |
530 |
|
531 | $avail_post_stati = get_available_post_statuses('post'); |
532 |
|
533 | $post_status_q = ''; |
534 | if ( isset($q['post_status']) && in_array( $q['post_status'], array_keys($post_stati) ) ) { |
535 | $post_status_q = '&post_status=' . $q['post_status']; |
536 | $post_status_q .= '&perm=readable'; |
537 | } |
538 |
|