Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save StewartChamberlain/6098216 to your computer and use it in GitHub Desktop.
Save StewartChamberlain/6098216 to your computer and use it in GitHub Desktop.
<?php
/** Do NOT include the opening php tag */
/** Offset posts on homepage */
add_action( 'pre_get_posts', 'sc_home_page_post_offset' );
function sc_home_page_post_offset( $query ) {
if ( is_home() )
$query->set ( 'offset', 1);
return $query;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment