
https://wordpress.org/plugins/news-ticker-benaceur/
ضع الكود التالي في ملف functions.php الخاص بقالبك المفعّل:
put this code in functions.php file of your active theme:
function ben_ntb_funct_filter_title( $string, $ntb ) {
# 'd M Y H-i'| d/m/Y H-i
$d = '<div class="ben_ntb_funct_filter_title"><div class="ben_ntb_funct_filter_title-str s1">';
$d .= date_i18n( 'd/m/Y', strtotime( $ntb[0] ) );
$d .= '</div>';
return $d.'<div class="ben_ntb_funct_filter_title-str">'.$string.'</div></div>';
}
add_filter( 'ntb_title_filter_ben', 'ben_ntb_funct_filter_title', 10, 3 );
function ben_ntb_funct_filter_title_style() {
echo '<style>
.ben_ntb_funct_filter_title-str.s1 {color:red;font-weight: bold;font-size: 12px;padding:0 3px;}
.ben_ntb_funct_filter_title .ben_ntb_funct_filter_title-str {display:inline-block;}
</style>';
}
add_action( 'wp_head', 'ben_ntb_funct_filter_title_style' );
ولإظهار كاتب الموضوع غيّر هذا السطر:
To display the author change this line:
$d .= date_i18n( 'd/m/Y', strtotime( $ntb[0] ) );
إلى:
to:
$d .= $ntb[1];
ولإظهار تاريخ آخر تعديل للموضوع عدل السطر إلى:
and to display the post modification date change to:
$d .= date_i18n( 'd/m/Y', strtotime( $ntb[2] ) );
ولإظهار عدد تعليقات الموضوع عدّل السطر إلى:
and to display comment count change to:
$d .= $ntb[3];
- إقرأ الموضوع كاملا …