Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: the_posts

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
2329                          if ( 'publish' != $sticky_post->post_status )
2330                               continue;
2331                               array_splice($this->posts, $sticky_offset, 0, array($sticky_post));
2332                               $sticky_offset++;
2333                     }
2334                }
2335           }
2336
2337           if ( !$q['suppress_filters'] )
2338                $this->posts = apply_filters('the_posts', $this->posts);
2339
2340           update_post_caches($this->posts);
2341
2342           $this->post_count = count($this->posts);
2343           if ($this->post_count > 0) {
2344                $this->post = $this->posts[0];
2345           }
2346
2347           return $this->posts;