<?php
/**
 * @package SKT Nature One
 */
?>

<div class="article-wrapper">
<article id="post-<?php the_ID(); ?>" <?php post_class('homepage-article'); ?>>
	<div class="featured-image">
	<?php if (has_post_thumbnail()) : ?>
		<a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('nature-one-homepage-thumb'); ?></a>
	<?php else: ?>	
		<a href="<?php the_permalink(); ?>"><img src="<?php echo esc_url(get_template_directory_uri()."/images/dthumb.jpg"); ?>"></a>
	<?php endif; ?>	
	</div>
	<header class="entry-header">
		<?php 
			if (strlen(get_the_title()) >= 85) { ?>
				<a href="<?php the_permalink(); ?>" data-title="<?php the_title(); ?>" rel="bookmark"><h1 class="entry-title">
		<?php echo substr(get_the_title(), 0, 84)."..."?></h1></a>
		<?php
		}
			else { ?>
			<a href="<?php the_permalink(); ?>" rel="bookmark"><h1 class="entry-title">
		<?php	the_title();	
			}	
				 ?>
	</h1></a>
	</header><!-- .entry-header -->
</article><!-- #post-## -->
</div>