WordPress.org

Support

Support » Plugins and Hacks » Custom Post Type UI » [Resolved] [Plugin: Custom Post Type UI] Add Post excerpt to my WP_query

[Resolved] [Plugin: Custom Post Type UI] Add Post excerpt to my WP_query

Viewing 1 replies (of 1 total)
  • DONE IT

    <?php $loop = new WP_Query( array( 'post_type' => 'movies','actors' => 'peter-smith', 'actress' => 'jane-smith', 'posts_per_page' => 10 ) ); ?>
    <?php while ( $loop->have_posts() ) : $loop->the_post(); ?>
    
    <?php the_title( '<h2 class="entry-title"><a href="' . get_permalink() . '" title="' . the_title_attribute( 'echo=0' ) . '" rel="bookmark">', '</a></h2>' ); ?>
    
    <h5>image</h5><a href="<?php the_permalink(); ?>"><img src="<?php the_field('image'); ?>" alt="text-here" /></a>
    <?php the_excerpt(); ?>
    <?php endwhile; ?>

Viewing 1 replies (of 1 total)
  • The topic ‘[Resolved] [Plugin: Custom Post Type UI] Add Post excerpt to my WP_query’ is closed to new replies.
Skip to toolbar