Try this one
<?php
echo get_the_post_thumbnail($post_id, 'thumbnail', array('class' => 'alignleft'));
?>
You can also get it from post_meta like this:
echo get_post_meta($post->ID, 'featured_image', true);
If you want JUST the source, and not an array with other information:
<?php $url = wp_get_attachment_url( get_post_thumbnail_id($post->ID), 'thumbnail' ); ?>
<img src="<?php echo $url ?>" />
<?php
if (has_post_thumbnail( $post->ID ) ):
$image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'single-post-thumbnail' );
?>
<img src="<?php echo $image[0]; ?>">
<?php endif; ?>
If the post is an image and we already know what the image is, it's possible to get the thumbnail URL without too much hassle:
echo pathinfo($image->guid, PATHINFO_DIRNAME);
You can also get the URL for image attachments as follows. It works fine.
if (has_post_thumbnail()) {
$image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'medium');
}