Title: 2nd featured image wordpress
Last modified: August 30, 2016

---

# 2nd featured image wordpress

 *  Resolved [tiksen](https://wordpress.org/support/users/tiksen/)
 * (@tiksen)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/2nd-featured-image-wordpress/)
 * Hi,
    I am trying to add a second featured image to my php files.
 * I downloaded the custom fields plugin and followed the guide: [http://wpsites.net/web-design/how-to-add-a-2nd-meta-box-for-a-different-featured-image/](http://wpsites.net/web-design/how-to-add-a-2nd-meta-box-for-a-different-featured-image/)
 * I added the code to my functions, and created a 2nd feature box that is showing
   up in my posts pages – but now I need the posts php to pull the 2nd featured 
   image that I created instead of the original wordpress feature image.
 * I dont have much php knowlede… can someone please tell me what code I should 
   put into the following content.php:
 *     ```
       <?php
       /**
        * The default template for displaying content
        *
        * Used for both single and index/archive/search.
        *
        * @package WordPress
        * @subpackage Miinto
        * @since Miinto
        */
       ?>
   
       <?php if (is_category() || is_tag() || is_author() || is_year() || is_month() || is_day()) { ?>
   
       	<div class="mosaicflow__item">
       		<a href="<?php the_permalink(); ?>" rel="bookmark">
       			<?php if (has_post_thumbnail()) { ?>
       				<?php the_post_thumbnail('thumbnail'); ?>
       			<?php } else { ?>
       				<img src="<?php echo get_template_directory_uri(); ?>/images/coming-soon.png">
       			<?php } ?>
       		</a>
       		<a href="<?php the_permalink(); ?>" rel="bookmark">
       			<h3><?php echo the_title(); ?></h3>
       		</a>
       		<p><?php the_time(get_option('date_format')); ?></p>
       	</div>
   
       <?php } else { ?>
   
       	<article class="block">
   
       	<header class="block">
   
       	<?php
   
       if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
       	the_post_thumbnail();
       }
       ?>
   
        <h1><a href="<?php the_permalink(); ?>" rel="bookmark"> — &nbsp;<?php the_title(); ?> &nbsp; —</a></h1>
       		</header>
   
       		<div class="block title-bottom">
       <!-- 			Posted at <?php //the_time(get_option('date_format')); ?> by <?php //the_author_posts_link(); ?> in <?php //the_category(', '); ?>
       			<?php //edit_post_link(null, '&raquo; '); ?> -->		<!--	 <?php the_author_posts_link(); ?>  ·  <?php the_time(get_option('date_format')); ?>  ·  <?php the_category(', '); ?>	-->		<?php //edit_post_link(null, '&raquo; '); ?>
       		</div>
   
       		<div class="block">
       			<?php the_content(); ?>
       		</div>
   
       		<footer class="block">
       			<div>
       				TAGS: <?php the_tags('', ', '); ?>
       <?php echo '<hr />'; ?>
   
       			</div>
       		</footer>
   
       	</article>
   
       <?php } ?>
       ```
   
 * Any help is greatly appreciated
    Link to site example post page: [http://miinfashtest.com/2-delte-blog-saet/](http://miinfashtest.com/2-delte-blog-saet/)

The topic ‘2nd featured image wordpress’ is closed to new replies.

 * 0 replies
 * 1 participant
 * Last reply from: [tiksen](https://wordpress.org/support/users/tiksen/)
 * Last activity: [10 years, 11 months ago](https://wordpress.org/support/topic/2nd-featured-image-wordpress/)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
