*/ global $post,$canuck_feature_pic_count; $category = esc_html( ( '' === get_post_meta( $post->ID, 'canuck_portfolio_category', true ) ? false : esc_html( get_post_meta( $post->ID, 'canuck_portfolio_category', true ) ) ) ); $display_post_content = ( '' === get_post_meta( $post->ID, 'canuck_metabox_include_post_content', true ) ? false : true ); $display_post_content_title = ( '' === get_post_meta( $post->ID, 'canuck_metabox_include_post_content_title', true ) ? false : true ); $display_image_caption = ( '' === get_post_meta( $post->ID, 'canuck_metabox_include_image_caption', true ) ? false : true ); $display_image_description = ( '' === get_post_meta( $post->ID, 'canuck_metabox_include_image_description', true ) ? false : true ); $include_pinterest_pinit = get_theme_mod( 'canuck_include_pinit' ) ? true : false; $category_id = get_cat_ID( $category ); $args = array( 'category' => $category_id, 'numberposts' => 20, ); $custom_posts = get_posts( $args ); if ( 0 !== $category_id && $custom_posts ) { $canuck_feature_pic_count = 0; ?>
ID, 'canuck_metabox_link_to_post', true ) ? false : true ); $custom_feature_link = ( '' === get_post_meta( $post->ID, 'canuck_custom_feature_link', true ) ? false : get_post_meta( $post->ID, 'canuck_custom_feature_link', true ) ); $image_url = get_the_post_thumbnail_url( $post->ID, 'canuck_med15' ); $post_title = the_title_attribute( 'echo=0' ); $post_content = get_the_content(); $image_caption = get_post( get_post_thumbnail_id() )->post_excerpt; $image_desc = get_post( get_post_thumbnail_id() )->post_content; if ( has_post_thumbnail() ) { if ( 0 === $canuck_feature_pic_count || is_int( $canuck_feature_pic_count / 2 ) ) { ?>
'; } else { echo '' . esc_attr( $image_caption ) . ''; } ?>
'; } if ( false !== $custom_feature_link ) { echo ''; } elseif ( true === $link_to_post ) { echo ''; } echo ''; ?>

'; } } } ?>