cancel_comment_reply_link

過濾鉤子
apply_filters( 'cancel_comment_reply_link', $formatted_link, $link, $text )
引數
  • (string) $formatted_link The HTML-formatted cancel comment reply link.
    Required:
  • (string) $link Cancel comment reply link URL.
    Required:
  • (string) $text Cancel comment reply link text.
    Required:
定義位置
相關勾子
comment_reply_linkcomment_reply_link_argsget_comment_linkwp_comment_replyedit_comment_link
相關方法
cancel_comment_reply_linkget_cancel_comment_reply_linkget_comment_reply_linkcomment_reply_linknext_comments_linkrender_block_core_comment_reply_link
引入
2.7.0
棄用
-

cancel_comment_reply_link: 這是WordPress的一個過濾鉤子,允許開發者修改評論表單中”取消回覆”連結的HTML輸出。cancel_comment_reply_link鉤子將預設的HTML輸出作為一個引數,鉤子函式可以返回一個修改後的HTML字串來代替。這對於改變”取消回覆”連結的外觀或行為很有用。

過濾取消評論回覆連結的HTML。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
return apply_filters( 'cancel_comment_reply_link', $formatted_link, $link, $text );
return apply_filters( 'cancel_comment_reply_link', $formatted_link, $link, $text );
return apply_filters( 'cancel_comment_reply_link', $formatted_link, $link, $text );

常見問題

FAQs
檢視更多 >