comment_excerpt_length

過濾鉤子
apply_filters( 'comment_excerpt_length', $comment_excerpt_length )
引數
  • (int) $comment_excerpt_length The amount of words you want to display in the comment excerpt.
    Required:
定義位置
相關勾子
comment_excerptget_comment_excerptcomment_reply_linkcomment_textcomment_atom_entry
相關方法
comment_excerptget_comment_excerptcomment_reply_linkcomment_textcomment_text_rsscomments_open
引入
4.4.0
棄用
-

comment_excerpt_length: 這是一個過濾鉤子,在檢索評論的摘錄長度時被執行。這個鉤子的唯一引數是長度,它應該返回這個長度。這個鉤子的目的是允許外掛或主題修改一個評論的摘錄長度。

過濾評論摘錄中使用的最大字數。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
$comment_excerpt_length = apply_filters( 'comment_excerpt_length', $comment_excerpt_length );
$comment_excerpt_length = apply_filters( 'comment_excerpt_length', $comment_excerpt_length );
$comment_excerpt_length = apply_filters( 'comment_excerpt_length', $comment_excerpt_length );

常見問題

FAQs
檢視更多 >