File "content-ajax.php"
Full Path: /var/www/bvnghean.vn/save_bvnghean.vn/wp-content/themes/publisher/views/general/post/content-ajax.php
File size: 3.5 KB
MIME-type: text/x-php
Charset: utf-8
<?php
/**
* post.php
*---------------------------
* The template for displaying posts
*
*/
the_post();
$post_format = get_post_format();
$thumbnail_size = 'publisher-lg';
if ( publisher_get_page_layout() == '1-col' ) {
$thumbnail_size = 'publisher-full';
}
$img = publisher_get_thumbnail( $thumbnail_size );
$post_settings = publisher_get_option( 'post-page-settings' );
?>
<div class="ajax-post-content">
<div class="single-container">
<article <?php publisher_attr( 'post', 'post single-post-content ' . ( ! empty( $img['src'] ) ? 'has-thumbnail' : '' ) ); ?>>
<div class="single-featured">
<?php
// Gallery Post Format
if ( $post_format == 'gallery' ) {
publisher_get_view( 'post', '_gallery' );
} // Video/Audio Post Format
elseif ( $post_format == 'video' || $post_format == 'audio' ) {
echo do_shortcode( apply_filters( 'better-framework/content/auto-embed', bf_get_post_meta( '_featured_embed_code' ) ) );
} // Simple Thumbnail
elseif ( ! empty( $img['src'] ) ) {
?>
<a <?php publisher_attr( 'post-thumbnail-url', '', 'full' ); ?>>
<img src="<?php echo $img['src']; ?>" alt="<?php the_title_attribute(); ?>">
</a>
<?php
}
if ( bf_get_post_meta( 'bs_featured_image_credit' ) != '' ) {
?>
<span class="image-credit"><?php bf_echo_post_meta( 'bs_featured_image_credit' ); ?></span>
<?php
}
?>
</div>
<div class="post-header-inner">
<div class="post-header-title">
<?php publisher_cats_badge_code( $post_format ? 2 : 3, '', TRUE, TRUE, 'floated' ); ?>
<h1 class="single-post-title">
<span <?php publisher_attr( 'post-title' ); ?>><?php the_title(); ?></span>
</h1>
<?php
if ( $post_settings['meta']['show'] ) {
publisher_set_prop( 'hide-meta-author', ! $post_settings['meta']['author'] );
publisher_set_prop( 'hide-meta-date', ! $post_settings['meta']['date'] );
publisher_set_prop( 'hide-meta-views', ! $post_settings['meta']['views'] );
publisher_set_prop( 'hide-meta-comment', ! $post_settings['meta']['comment'] );
publisher_set_prop( 'hide-meta-review', ! $post_settings['meta']['review'] );
publisher_get_view( 'post', '_meta' );
}
?>
</div>
</div>
<?php
// Social share buttons
if ( publisher_get_option( 'social_share_single' ) == 'show' ) {
publisher_listing_social_share( '', 'single-post-share', TRUE );
}
?>
<div <?php publisher_attr( 'post-content', 'clearfix single-post-content' ); ?>>
<?php publisher_the_content(); ?>
</div>
<?php
// Shows source
if ( bf_get_post_meta( '_bs_source_url' ) || bf_get_post_meta( '_bs_source_url_2' ) || bf_get_post_meta( '_bs_source_url_3' ) ) {
publisher_get_view( 'post', '_source', 'default' );
}
// Shows via
if ( bf_get_post_meta( '_bs_via_url' ) || bf_get_post_meta( '_bs_via_url_2' ) || bf_get_post_meta( '_bs_via_url_3' ) ) {
publisher_get_view( 'post', '_via', 'default' );
}
// Shows post tags
if ( publisher_has_tag() ) {
publisher_get_view( 'post', '_tags', 'default' );
}
// post info for SEO
publisher_get_view( 'post', '_info', 'default' );
?>
</article>
<?php
// Author box
if ( publisher_get_option( 'post_author_box' ) == 'show' ) {
publisher_get_view( 'post', '_author' );
}
?>
</div>
<?php
// Comments and comment form
publisher_comments_template();
// After ajaxed post
publisher_show_ad_location( 'post_ajax_related', array( 'container-class' => 'adloc-ajaxed-related' ) );
?>
</div>