久久99国产精品片久久99蜜桃_久久精品99国产精品蜜桃_久久久亚洲AV成人网站_欧美精品色婷婷五月综合_亚洲精品乱码久久久久久蜜桃图片_夜夜高潮夜夜爽国产伦精品_69无人区乱码一二三四区别_日产一码二码三码区别_大香区一二三四区2021_国产精品爱久久久久久久,日本高清视频成人网www,国产亚洲一二三区精品免费视频观看,久久久精品国产SM调教网站

推廣 熱搜: 后臺  帝國cms  位置  網(wǎng)站  Wordpress教程  帝國cms建站  內(nèi)容  DESTOON  郵箱  destoon7.0 

WordPress回復(fù)評論文字的修改方法

   日期:2019-04-20     瀏覽:129    違規(guī)舉報(bào)
 
騰訊云服務(wù)器優(yōu)惠

許多實(shí)用WordPress的很多站長可能都需要修改回復(fù)評論文字,,下面就教大家如何修改回復(fù)評論文字內(nèi)容,。

首選需要建立個(gè)自定義的評論模板,然后通過調(diào)用此評論函數(shù)來實(shí)現(xiàn)自定義,,通過以下代碼可以實(shí)現(xiàn)修改回復(fù)文字:

<?php $defaults = array(  'add_below' => 'comment',  'respond_id' => 'respond',  'reply_text' => __('Reply'),  'login_text' => __('Reply'),  'depth' => 0,  'before' => '',  'after' => '' ); comment_reply_link(  array_merge(   $defaults,   array('depth' => $depth, 'max_depth' => $args['max_depth'])  ) )?>

你可以將Reply修改成你希望的文字,。

$defaults = array('add_below' => 'comment', 'respond_id' => 'respond', 'reply_text' => __('Reply')

這行是默認(rèn)的回復(fù)評論。

'login_text' => __('Reply'), 'depth' => 0, 'before' => '', 'after' => '');

這行是登陸后評論,。

comment_reply_link(array_merge( $defaults, array('depth' => $depth, 'max_depth' => $args['max_depth'])))

這行是評論鏈接,。將以上代碼放在評論 loop 內(nèi)既可使用,下面是完整的 custom_comment.php 函數(shù)文件:

<?phpif (!function_exists("custom_comment")) {function custom_comment($comment, $args, $depth) {$GLOBALS['comment'] = $comment; ?><li <?php comment_class(); ?>><a name="comment-<?php comment_ID() ?>"></a><?php if(get_comment_type() == "comment"){ ?><?php the_commenter_avatar($args) ?><?php } ?><?php$defaults = array('add_below' => 'comment', 'respond_id' => 'respond', 'reply_text' => __('Reply'),'login_text' => __('Reply'), 'depth' => 0, 'before' => '', 'after' => '');comment_reply_link(array_merge( $defaults, array('depth' => $depth, 'max_depth' => $args['max_depth']))) ?><?php the_commenter_link() ?><?php echo get_comment_date(get_option( 'date_format' )) ?> <?php _e('at', 'jintu'); ?> <?php echo get_comment_time(get_option( 'time_format' )); ?><?php edit_comment_link(__('Edit', 'jintu'), '', ''); ?><?php comment_text() ?><?php if ($comment->comment_approved == '0') { ?><p class='unapproved'><?php _e('Your comment is awaiting moderation.', 'jintu'); ?></p><?php } ?><?php}}?>

將上面的代碼保存到 custom_comment.php 文件,, 在functions.php里加載即可,,wordpress修改回復(fù)文字的方法就這么簡單,。

免責(zé)聲明:
1、本站所收集的部分公開資料來源于互聯(lián)網(wǎng),,轉(zhuǎn)載的目的在于傳遞更多信息及用于網(wǎng)絡(luò)分享,,并不代表本站贊同其觀點(diǎn)和對其真實(shí)性負(fù)責(zé),也不構(gòu)成任何其他建議,。
2,、本站部分作品內(nèi)容是由網(wǎng)友自主投稿和發(fā)布、編輯整理上傳,,對此類內(nèi)容本站僅提供交流平臺,,不為其版權(quán)負(fù)責(zé),更不為其觀點(diǎn)承擔(dān)任何責(zé)任,。
3,、因行業(yè)及專業(yè)性有限,故未能核驗(yàn)會員發(fā)布內(nèi)容的真實(shí)性及有效性,,不為其負(fù)責(zé),,如有虛假或違規(guī)內(nèi)容敬請準(zhǔn)備材料圖片發(fā)郵件到info@n#舉報(bào),本站核實(shí)后積極配合刪除,。
4,、如果您發(fā)現(xiàn)網(wǎng)站上有侵犯您的知識產(chǎn)權(quán)的作品,請與我們?nèi)〉寐?lián)系,,我們會及時(shí)處理或刪除,。
 
標(biāo)簽: Wordpress教程 文件 模板 希望
打賞
 
更多>同類網(wǎng)站技術(shù)
0相關(guān)評論

推薦圖文
推薦網(wǎng)站技術(shù)
點(diǎn)擊排行
網(wǎng)站首頁  |  關(guān)于我們  |  聯(lián)系方式  |  使用協(xié)議  |  免責(zé)聲明  |  版權(quán)隱私  |  信息發(fā)布規(guī)則  |  網(wǎng)站地圖  |  排名推廣  |  廣告服務(wù)  |  積分換禮  |  網(wǎng)站留言  |  RSS訂閱  |  違規(guī)舉報(bào)  |  粵ICP備2020081222號
Powered By DESTOON