Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php $args = array (
- 'posts_per_page' => '-1',
- 'post_type' => 'works'
- );
- $work_list = new WP_Query($args);
- ?>
- <?php if( $work_list->have_posts() ):?>
- <?php while( $work_list->have_posts() ) : $work_list->the_post();?>
- <?php
- echo ' <div id="work-post">
- <a href="'. get_permalink($post->ID) .'">
- <div id="work-thumbnail">
- <img src="' . get_field("work_image") . '" alt="Avatar" class="image">
- </div>
- </a>
- </div>';
- ?>
- <?php endwhile;?>
- <?php endif; ?>
- <?php wp_reset_query(); // Restore global post data stomped by the_post(). ?>
- foreach(get_the_category as $category) {
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement