Created
February 8, 2012 13:48
-
-
Save Ahrengot/1769687 to your computer and use it in GitHub Desktop.
Alter primary loop
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Used to alter main loop. For secondary loops use get_posts() or make a new instance of WP_Query() | |
<?php | |
query_posts( array ( 'post_type' => 'artists', 'posts_per_page' => -1, 'order' => 'ASC' ) ); | |
if(have_posts()) : while (have_posts()) : the_post(); | |
?> | |
<!-- stuff like the_title(); --> | |
<?php | |
endwhile; | |
endif; | |
wp_reset_query(); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment