Skip to main content

get posts from category name

     <?php
//query_posts('category_name=Key Individuals&orderby=menu_order&order=ASC');
query_posts('category_name=blog-3');
//query_posts('category_name=blog&order=DESC');
if ( have_posts() ) while ( have_posts() ) : the_post(); ?>

<div class="post" id="post-<?php the_ID(); ?>" <?php post_class(); ?>>


<div class="entry-content">
                    <div class="dmo-contain">
                    <div class="dmo-img">
<?php
//This must be in one loop

if(has_post_thumbnail()) {
the_post_thumbnail();
                                                           
}?>

</div>
                    <div class="dmo-txt">
                    <?php if ( is_front_page() ) { ?>
<h2 class="entry-title"><?php the_title(); ?></h2>
<?php } else { ?>
<h1 class="entry-title"><?php the_title(); ?></h1>
<?php } ?>
<?php the_excerpt(); ?>
                        </div>
<?php //wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', 'twentyten' ), 'after' => '</div>' ) ); ?>
<?php //edit_post_link( __( 'Edit', 'twentyten' ), '<span class="edit-link">', '</span>' ); ?>
                        </div>
</div><!-- .entry-content -->
</div><!-- #post-## -->

<?php //( '', true ); ?>

<?php endwhile; ?>

Comments

Popular posts from this blog

add custom post type

/**  *  * add custom post type  *  */ function my_custom_post_product() {   $labels = array(     'name'               => _x( 'Products', 'post type general name' ),     'singular_name'      => _x( 'Product', 'post type singular name' ),     'add_new'            => _x( 'Add New', 'book' ),     'add_new_item'       => __( 'Add New Product' ),     'edit_item'          => __( 'Edit Product' ),     'new_item'           => __( 'New Product' ),     'all_items'          => __( 'All Products' ),     'vi...

Toolset conditional

[wpv- if evaluate= "'[wpv-current-user info='id']' = '[wpv-post-author format='meta' meta='ID']' OR '[wpv-current-user info='role']' = 'administrator'" ]      //the content you want to hide goes here [/wpv- if ]