Revision: 31033
Updated Code
at August 27, 2010 17:05 by ivorpad
Updated Code
<?php query_posts( 'post_type=work&posts_per_page=1'.'&paged='.$paged); ?> <?php if (have_posts()) : while (have_posts()) : the_post(); ?> <li class="illustrations"> <?php the_title('<h4 class="nice-titles"><a href="' . get_permalink() . '" title="' . the_title_attribute( 'echo=0' ) . '" rel="bookmark">', '</a></h4>' ); ?> <?php if(has_post_thumbnail()) { the_post_thumbnail(); } else { echo '<img src="'.get_bloginfo("template_url").'/images/default_img.jpg" />'; } ?> <?php the_excerpt(); ?> <a href="<?php the_permalink(); ?>">More...</a> </li> <!-- /item --> <?php endwhile; ?> <div class="navigation"> <div class="alignleft"><?php next_posts_link('« Previous Entries') ?></div> <div class="alignright"><?php previous_posts_link('Next Entries »') ?></div> </div> <?php else: ?> <p><?php _e('Not Found','ivorpad'); ?></p> <?php endif; ?>
Revision: 31032
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at August 27, 2010 17:00 by ivorpad
Initial Code
<?php query_posts( 'post_type=work&posts_per_page=1'.'&paged='.$paged); ?> <?php if (have_posts()) : while (have_posts()) : the_post(); ?> <!-- item --> <li class="illustrations"> <div class="content_block"> <?php the_title('<h4 class="nice-titles"><a href="' . get_permalink() . '" title="' . the_title_attribute( 'echo=0' ) . '" rel="bookmark">', '</a></h4>' ); ?> <?php if(has_post_thumbnail()) { the_post_thumbnail(); } else { echo '<img src="'.get_bloginfo("template_url").'/images/default_img.jpg" />'; } ?> <span><a href="showcase/4/big_slide_1.jpg" rel="prettyPhoto[gallery]">Zoom</a> - <a href="<?php the_permalink(); ?>">Details</a></span> <?php the_excerpt(); ?> <p class="works_links"><a href="<?php the_permalink(); ?>"><span class="inv">More...</span></a></p> </div> </li> <!-- /item --> <?php endwhile; ?> <div class="navigation"> <div class="alignleft"><?php next_posts_link('« Previous Entries') ?></div> <div class="alignright"><?php previous_posts_link('Next Entries »') ?></div> </div> <?php else: ?> <p><?php _e('Not Found','deathlab'); ?></p> <?php endif; ?>
Initial URL
Initial Description
This will fetch the custom post types, displayed as a list with their respective permalinks.
Initial Title
Display a list of Custom Post Types as a blog
Initial Tags
post, wordpress
Initial Language
PHP