OS : Linux
PHP Version : 7.4.33
Software : ' .
'<' . esc_html($tag) . ' class="cmsmasters_slider_post_title entry-title">' .
'' . cmsmasters_title($cmsmasters_id, false) . '' .
'' . esc_html($tag) . '>' .
'';
} elseif ($type == 'project') {
$out = '';
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider Content/Excerpt Function */
function total_school_slider_post_exc_cont($type = 'post', $show = true) {
if ($type == 'post') {
$out = cmsmasters_divpdel('' . "\n" .
wpautop(theme_excerpt(20, false)) .
'
' . "\n");
} elseif ($type == 'project') {
$out = cmsmasters_divpdel('' . "\n" .
wpautop(theme_excerpt(20, false)) .
'
' . "\n");
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Check Posts Slider Content/Excerpt Not Empty Function */
function total_school_slider_post_check_exc_cont($type = 'post') {
$exc = total_school_slider_post_exc_cont($type, false);
$no_tags_exc = strip_tags($exc);
$trim_exc = trim($no_tags_exc);
if ($trim_exc != '') {
return true;
} else {
return false;
}
}
/* Get Posts Slider Date Function */
function total_school_get_slider_post_date($show = true) {
$out = '' .
'' .
esc_html(get_the_date('M d, Y')) .
'' .
'' .
esc_html(get_the_modified_date()) .
'' .
'';
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider Author Function */
function total_school_get_slider_post_author($type = 'post', $show = true) {
if ($type == 'post') {
$out = '' .
esc_html__('By', 'total-school') . ' ' .
'' . esc_html(get_the_author_meta('display_name')) . '' .
'';
} elseif ($type == 'project') {
$out = '' .
esc_html__('By', 'total-school') . ' ' .
'' . esc_html(get_the_author_meta('display_name')) . '' .
'';
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider Category Function */
function total_school_get_slider_post_category($cmsmasters_id, $taxonomy, $type = 'post', $show = true) {
$out = '';
if (get_the_terms($cmsmasters_id, $taxonomy)) {
if ($type == 'post') {
$out = '' .
esc_html__('In ', 'total-school') .
total_school_get_the_category_list($cmsmasters_id, $taxonomy, ', ') .
'';
} elseif ($type == 'project') {
$out = '' .
total_school_get_the_category_list($cmsmasters_id, $taxonomy, ', ') .
'';
}
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider Like Function */
function total_school_slider_post_like($type = 'post', $show = true) {
$out = '';
if ($type == 'post') {
$out = cmsmasters_like('cmsmasters_slider_post_likes');
} elseif ($type == 'project') {
$out = cmsmasters_like('cmsmasters_slider_project_likes');
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider Comments Function */
function total_school_get_slider_post_comments($type = 'post', $show = true) {
$out = '';
if (comments_open()) {
if ($type == 'post') {
$out = total_school_get_comments('cmsmasters_slider_post_comments');
} elseif ($type == 'project') {
$out = total_school_get_comments('cmsmasters_slider_project_comments');
}
}
if ($show) {
echo $out;
} else {
return $out;
}
}
/* Get Posts Slider More Button/Link Function */
function total_school_slider_post_more($cmsmasters_id, $show = true) {
$cmsmasters_post_read_more = get_post_meta($cmsmasters_id, 'cmsmasters_post_read_more', true);
if ($cmsmasters_post_read_more == '') {
$cmsmasters_post_read_more = esc_attr__('Read More', 'total-school') . '...';
}
$out = '' . esc_html($cmsmasters_post_read_more) . '';
if ($show) {
echo $out;
} else {
return $out;
}
}