the_ID(); ?> " <?php post_class('clearfix wrap cb-article-content'); ?> role="article" itemscope itemtype="http://schema.org/BlogPosting"> <section class="entry-content clearfix" itemprop="articleBody"> <?php the_content(); ?> <?php wp_link_pages('before=<div class="cb-pagination clearfix">&after=</div>&next_or_number=number&pagelink=<span class="cb-page">%</span>'); ?> <?php echo cb_get_byline($post); ?> </section> <footer class="article-footer"> <?php cb_like_block($cb_post_id); if ($cb_ad_after_content != NULL) { echo '<div class="cb-post-block-after cb-post-footer-block clearfix">' . do_shortcode($cb_ad_after_content) . '</div>'; } cb_sharing_block($post); cb_the_tags($cb_post_id); ?> </footer>
function cb_get_post_format_data($cb_post_id, $cb_post_format_type = NULL) { $cb_output = $cb_audio_source = $cb_byline = NULL; if ($cb_post_format_type == 'gallery') { $cb_gallery_post_images = get_post_meta($cb_post_id, 'cb_gallery_post_images', true); $cb_post_gallery = cb_get_gallery_images($cb_post_id, $cb_gallery_post_images, 'full', $cb_captions = true); if ($cb_post_gallery != NULL) { $cb_byline = cb_get_byline($cb_post_id); $cb_output = '<div id="cb-featured-image" class="cb-fis cb-fis-big cb-fis-fs cb-fis-block-background cb-gallery-post-wrap clearfix"><div id="cb-gallery-post" class="cb-arrows-sides cb-background-preload"><ul class="slides">'; foreach ($cb_post_gallery as $cb_image) { if (trim($cb_image['cb-caption']) != '') { $cb_image['cb-caption'] = '<span class="cb-caption cb-credit-line">' . $cb_image['cb-caption'] . '</span>'; } $cb_output .= '<li><img src="' . esc_url($cb_image['cb-url']) . '">' . $cb_image['cb-caption'] . '</li>'; } $cb_output .= '</ul>'; $cb_output .= '<span class="cb-link-overlay"><div class="cb-entry-header cb-meta">'; $cb_output .= '<h1 class="entry-title cb-entry-title cb-title">' . get_the_title() . '</h1>' . $cb_byline; $cb_output .= '</div></span>'; $cb_output .= '</div></div>'; } } if ($cb_post_format_type == 'video') { $cb_video_output = get_post_meta($cb_post_id, 'cb_video_embed_code_post', true); $cb_video_post_select = get_post_meta($cb_post_id, 'cb_video_post_select', true); if ($cb_video_post_select == '1') { $cb_video_output = '<div class="cb-video-frame">' . $cb_video_output . '</div>'; } else { if (ot_get_option('cb_youtube_api', 'on') == 'on') { if (strpos($cb_video_output, 'yout') !== false) { preg_match('([-\\w]{11})', $cb_video_output, $cb_youtube_id); $cb_video_output = '<span id="cb-yt-player">' . $cb_youtube_id[0] . '</span>'; } } } $cb_output .= $cb_video_output; } if ($cb_post_format_type == 'audio') { $cb_audio_post_select = get_post_meta($cb_post_id, 'cb_audio_post_select', true); if ($cb_audio_post_select == 'external') { $cb_output .= '<div id="cb-media-embed-url" class="clearfix cb-audio-embed">' . get_post_meta($cb_post_id, 'cb_audio_post_url', true) . '</div>'; } elseif ($cb_audio_post_select == 'selfhosted') { $cb_audio_source_mp3 = get_post_meta($cb_post_id, 'cb_audio_post_selfhosted_mp3', true); $cb_audio_source_ogg = get_post_meta($cb_post_id, 'cb_audio_post_selfhosted_ogg', true); if ($cb_audio_source_mp3 != NULL || $cb_audio_source_mp3 != NULL) { $cb_audio_source = '<audio controls="controls">'; if ($cb_audio_source_mp3 != NULL) { $cb_audio_source .= '<source src="' . esc_url($cb_audio_source_mp3) . '" type="audio/mpeg" />'; } if ($cb_audio_source_ogg != NULL) { $cb_audio_source .= '<source src="' . esc_url($cb_audio_source_ogg) . '" type="audio/ogg" />'; } $cb_audio_source .= '</audio>'; } $cb_output .= '<div id="cb-media-embed-url" class="clearfix cb-audio-embed">' . $cb_audio_source . '</div>'; } } return $cb_output; }