Try this:
<?php get_header(); ?>
<div id="content" class="clearfix row">
<article id="post-<?php the_ID(); ?>" <?php post_class('clearfix'); ?> role="article">
<section id="work" class="row">
<div class="span3">
<h3>Recent Work</h3>
<p>Intro Lorem ipsum</p>
</div>
<?php $args = array(
'post_type' => 'portfolio',
'post_status' => 'publish',
'posts_per_page' => 3
);
$query = new WP_Query( $args );
$porfolio_post_ids = array();
if ( $query->have_posts() ) {
while ( $query->have_posts() ) {
global $post;
$query->the_post();
array_push( $porfolio_post_ids, $post->ID );
}
} ?>
<div class="span6">
<a href="https://wordpress.stackexchange.com/questions/48554/<?php echo get_permalink( $porfolio_post_ids[0] ); ?>">
<?php echo get_the_post_thumbnail(
$porfolio_post_ids[0] , 'medium'
); ?> <!--Should be from custom post 'A' -->
</a>
</div>
<div class="span3">
<a href="<?php echo get_permalink( $porfolio_post_ids[1] ); ?>" >
<?php echo get_the_post_thumbnail(
$porfolio_post_ids[1] , 'thumbnail'
); ?><!--Should be from custom post 'B' -->
</a>
<a href="<?php echo get_permalink( $porfolio_post_ids[2] ); ?>">
<?php echo get_the_post_thumbnail(
$porfolio_post_ids[2] , 'thumbnail'
); ?><!--Should be from custom post 'C' -->
</a>
</div>
and don’t forget to set the thumbnail in functions.php
as mentioned in David’s answer.
One more thing I noticed in your code: you said that your post type is “portfolio” and in the permalink you used single-project.php
, but shouldn’t it be single-portfolio.php
?