Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@KnowTheCodePro
Created May 10, 2016 22:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KnowTheCodePro/8c88f937c23b05945bc0993bf5b1c0f0 to your computer and use it in GitHub Desktop.
Save KnowTheCodePro/8c88f937c23b05945bc0993bf5b1c0f0 to your computer and use it in GitHub Desktop.
Genesis standard loop
if ( have_posts() ) :
do_action( 'genesis_before_while' );
while ( have_posts() ) : the_post();
...
endwhile;
do_action( 'genesis_after_endwhile' );
else : //* if no posts exist
do_action( 'genesis_loop_else' );
endif; //* end loop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment