$thumbnail_image_url = wp_get_attachment_image_src($thumbnail_image_id, 'large', true);
                $thumbnail_image = $thumbnail_image_url[0];
            } else {
                $thumbnail_image = get_template_directory_uri() . '/images/no-image.jpg';
            }
            $post_format = get_post_format();
            if (get_field('double_size') == true) {
                $double_size_class = 'portfolio-double-size';
            } else {
                $double_size_class = false;
            }
            // If standard post format
            // ------------------------------------------------------------------------------------
            if ($post_format == '') {
                // Get the featured image or first portfolio image
                $the_image = knacc_portfolio_first_image();
                ?>
						
						<li id="post-<?php 
                the_ID();
                ?>
" class="portfolio-item portfolio-post-format is-loading <?php 
                if ($double_size_class != false) {
                    echo $double_size_class;
                }
                ?>
">
							<a href="<?php 
                the_permalink();
                ?>
" <?php 
Example #2
0
/**
 * Display share buttons to social networks.
 */
function knacc_share_post()
{
    ?>
	<aside class="share-post">
		<h1 class="share-title"><?php 
    _e('Share', 'show-tell');
    ?>
</h1>
		<div class="share-links">
			<div class="share-link share-facebook"><a href="#" onclick="javascript:void(window.open('http://www.facebook.com/sharer.php?u=<?php 
    the_permalink();
    ?>
&amp;t=<?php 
    the_title();
    ?>
','sharer','toolbar=0,status=0,width=620,height=430').focus()); return false;" title="<?php 
    printf(__('Share on Facebook: %s', 'show-tell'), get_the_title());
    ?>
"><?php 
    _e('Facebook', 'show-tell');
    ?>
</a></div>
			<div class="share-link share-twitter"><a href="#" onclick="javascript:void(window.open('http://twitter.com/share?url=<?php 
    the_permalink();
    ?>
&amp;text=<?php 
    the_title();
    ?>
&amp;count=none/', 'tweet', 'height=300,width=550,resizable=1').focus()); return false;" title="<?php 
    printf(__('Share on Twitter: %s', 'show-tell'), get_the_title());
    ?>
" target="blank"><?php 
    _e('Twitter', 'show-tell');
    ?>
</a></div>
			<div class="share-link share-googleplus"><a href="#" onclick="javascript:void(window.open('https://m.google.com/app/plus/x/?v=compose&amp;content=<?php 
    the_title();
    ?>
 <?php 
    the_permalink();
    ?>
','sharer','toolbar=0,status=0,width=620,height=400').focus()); return false;" target="_blank"><?php 
    _e('Google +', 'show-tell');
    ?>
</a></div>
			<div class="share-link share-pinterest"><a href="#" onclick="javascript:void(window.open('http://pinterest.com/pin/create/button/?url=<?php 
    the_permalink();
    ?>
&amp;media=<?php 
    echo knacc_portfolio_first_image();
    ?>
&amp;description=<?php 
    the_title();
    ?>
 - <?php 
    bloginfo('name');
    ?>
','sharer','toolbar=0,status=0,width=620,height=280').focus()); return false;" title="<?php 
    printf(__('Pin it: %s', 'show-tell'), get_the_title());
    ?>
" target="_blank"><?php 
    _e('Pinterest', 'show-tell');
    ?>
</a></div>
		</div><!-- .nav-links -->
	</aside><!-- .navigation -->
<?php 
}