';
}
}
/**
* Jetpack integration
*
* @since 1.0.0
*/
private function jetpack_integration() {
if ( class_exists( 'Jetpack' ) ) :
if ( deep_has_featured_posts( 1 ) ) :
echo '
';
echo '
' . esc_html__( 'Featured Posts' , 'deep-free' ) . '
';
if( $this->post_count == '0' ) {
echo '
';
get_template_part('parts/blogloop');
echo '
';
} else {
echo '
';
get_template_part('parts/blogloop','type2');
echo '
';
}
echo '
';
$this->post_count ++;
endif;
endif;
}
/**
* Default template, Standard posts layout
*
* @since 1.0.0
*/
private function default_standard() {
echo '
';
}
/**
* Default template, List posts layout
*
* @since 1.0.0
*/
private function default_list() {
echo '
';
}
/**
* Default template, Standard then List posts layout
*
* @since 1.0.0
*/
private function default_standard_then_list() {
if ( $this->post_count == '0' ) {
echo '
';
}
$this->post_count ++;
}
/**
* Default template, Grid posts layout
*
* @since 1.0.0
*/
private function default_grid() {
get_template_part( 'parts/blogloop', 'type3' );
}
/**
* Default template, Standard then Grid posts layout
*
* @since 1.0.0
*/
private function default_standard_then_grid() {
if ( $this->post_count == '0' ) {
echo '
';
} else {
get_template_part('parts/blogloop','type3');
}
$this->post_count++;
}
/**
* Personal Blog template, Standard posts layout
*
* @since 1.0.0
*/
private function personal_blog_standard() {
echo '
';
get_template_part('parts/blogloop','type1');
echo '
';
}
/**
* Personal Blog template, List posts layout
*
* @since 1.0.0
*/
private function personal_blog_list() {
echo '
';
get_template_part('parts/blogloop','type5');
echo '
';
}
/**
* Personal Blog template, Standard then List posts layout
*
* @since 1.0.0
*/
private function personal_blog_standard_then_list() {
if( $this->post_count == '0' ) {
echo '
';
get_template_part('parts/blogloop','type1');
echo '
';
} else {
echo '
';
get_template_part('parts/blogloop','type5');
echo '
';
}
$this->post_count++;
}
/**
* Personal Blog template, Grid posts layout
*
* @since 1.0.0
*/
private function personal_blog_grid() {
echo '
';
get_template_part('parts/blogloop','type7');
echo '
';
}
/**
* Personal Blog template, Standard then Grid posts layout
*
* @since 1.0.0
*/
private function personal_blog_standard_then_grid() {
$classes = $this->post_count == '0' ? 'blgtyp10 blg-personal-full' : 'col-md-6 blg-typ3 blgtyp10 blg-personal-grid';
if ( $this->post_count == '0' ) {
echo '
';
get_template_part( 'parts/blogloop', 'type1' );
echo '
';
} else {
echo '
';
get_template_part( 'parts/blogloop', 'type7' );
echo '
';
}
$this->post_count++;
}
/**
* Magazine template, Standard posts layout
*
* @since 1.0.0
*/
private function magazine_standard() {
echo '
';
if( $this->post_count == '0' ) {
get_template_part('parts/blogloop','type6');
}
echo '
';
}
/**
* Magazine template, List posts layout
*
* @since 1.0.0
*/
private function magazine_list() {
echo '
';
get_template_part('parts/blogloop','type4');
echo '
';
}
/**
* Magazine template, Standard then List posts layout
*
* @since 1.0.0
*/
private function magazine_standard_then_list() {
if( $this->post_count == '0' ) {
echo '
';
get_template_part('parts/blogloop','type6');
echo '
';
} else {
echo '
';
get_template_part('parts/blogloop','type4');
echo '
';
}
$this->post_count++;
}
/**
* Magazine template, Grid posts layout
*
* @since 1.0.0
*/
private function magazine_grid() {
if ( $this->post_count % 2 == 0 ) {
echo '
';
}
echo '
';
echo '
';
get_template_part('parts/blogloop','type8');
echo '
';
echo '
';
if ( $this->post_count % 2 == 1 ) {
echo '
';
}
$this->post_count++;
}
/**
* Magazine template, Standard then Grid posts layout
*
* @since 1.0.0
*/
private function magazine_standard_then_grid() {
$classes = $this->post_count == '0' ? 'blgtyp11 blg-magazine-full' : ' blg-magazine-grid col-md-6 blg-typ3 blgtyp11';
echo '
';
if( $this->post_count == '0' ) {
get_template_part('parts/blogloop','type6');
} else {
get_template_part('parts/blogloop','type8');
}
$this->post_count++;
echo '
';
}
/**
* Masonry posts layout
*
* @since 1.0.0
*/
private function masonry() {
get_template_part( 'parts/blogloop','masonry' );
}
/**
* Timline posts layout
*
* @since 1.0.0
*/
private function timeline() {
global $post;
$timeline_last_time = get_the_time(get_option( 'date_format' ));
$timeline_i = 1;
$timeline_flag = false;
$post_id = $post->ID;
$post_format = get_post_format( $post_id );
$content = get_the_content();
if ( ! $post_format ) {
$post_format = 'standard';
}
if ( ( $timeline_last_time != date( ' F Y', strtotime( $post->post_date ) ) ) || $timeline_i == 1 ) {
$timeline_last_time = date(' F Y', strtotime( $post->post_date ) );
echo '
' . wp_kses( date( ' F Y', strtotime( $post->post_date ) ), wp_kses_allowed_html( 'post' ) ) . '
';
if ( $timeline_i > 1 ) {
$timeline_flag = true;
}
}
?>
enable_category_meta ): ?>
enable_post_title ) {
if ( ( 'aside' != $post_format ) && ('quote' != $post_format ) ) {
if ( 'link' == $post_format ) {
preg_match( '/\b(?:(?:https?|ftp):\/\/|www\.)[-a-z0-9+&@#\/%?=~_|!:,.;]*[-a-z0-9+&@#\/%=~_|]/i', $content, $matches );
$content = preg_replace( '/\b(?:(?:https?|ftp):\/\/|www\.)[-a-z0-9+&@#\/%?=~_|!:,.;]*[-a-z0-9+&@#\/%=~_|]/i','', $content, 1 );
$link ='';
if ( isset( $matches ) && is_array( $matches ) ) {
$link = $matches[0];
}
?>
';
echo wp_kses( deep_excerpt(31), wp_kses_allowed_html( 'post' ) );
echo '';
}
?>
enable_featured_image ) {
$meta_video = rwmb_meta( 'deep_featured_video_meta' );
if ( $post_format == 'video' || $post_format == 'audio' ) {
$pattern = '\\[' . '(\\[?)' . "(video|audio)" . '(?![\\w-])' . '(' . '[^\\]\\/]*' . '(?:' . '\\/(?!\\])' . '[^\\]\\/]*' . ')*?' . ')' . '(?:' . '(\\/)' . '\\]' . '|' . '\\]' . '(?:' . '(' . '[^\\[]*+' . '(?:' . '\\[(?!\\/\\2\\])' . '[^\\[]*+' . ')*+' . ')' . '\\[\\/\\2\\]' . ')?' . ')' . '(\\]?)';
preg_match( '/' . $pattern . '/s', $post->post_content, $matches );
if ( ( is_array( $matches) ) && ( isset( $matches[3] ) ) && ( ( $matches[2] == 'video' ) || ( 'audio' == $post_format ) ) && ( isset($matches[2] ) ) ) {
$video = $matches[0];
echo do_shortcode($video);
$content = preg_replace('/'.$pattern.'/s', '', $content);
} elseif ( (! empty( $meta_video )) ) {
echo do_shortcode($meta_video);
}
} else {
if( 'gallery' == $post_format){
$pattern = '\\[' . '(\\[?)' . "(gallery)" . '(?![\\w-])' . '(' . '[^\\]\\/]*' . '(?:' . '\\/(?!\\])' . '[^\\]\\/]*' . ')*?' . ')' . '(?:' . '(\\/)' . '\\]' . '|' . '\\]' . '(?:' . '(' . '[^\\[]*+' . '(?:' . '\\[(?!\\/\\2\\])' . '[^\\[]*+' . ')*+' . ')' . '\\[\\/\\2\\]' . ')?' . ')' . '(\\]?)';
preg_match( '/' . $pattern . '/s', $post->post_content, $matches );
if ( ( is_array( $matches ) ) && ( isset($matches[3])) && ( $matches[2] == 'gallery' ) && ( isset( $matches[2] ) ) ) {
$ids = ( shortcode_parse_atts( $matches[3] ) );
if ( is_array( $ids ) && isset( $ids['ids'] ) ) {
$ids = $ids['ids'];
}
echo wp_kses( get_post_gallery(), wp_kses_allowed_html( 'post' ) );
$content = preg_replace('/'.$pattern.'/s', '', $content);
}
} else {
if ( $thumbnail_url ) { ?>
template_layout == '7' ) {
echo'
'. wp_kses( get_the_time(get_option( 'date_format' )), wp_kses_allowed_html( 'post' ) ) .'
';
}
if ( $this->template_layout == '3' || $this->template_layout == '6' || $this->template_layout == '7' ) {
echo '