rss_enclosure

過濾鉤子
apply_filters( 'rss_enclosure', '
引數
  • (string) $html_link_tag The HTML link tag with a URI and other attributes.
    Required:
    Default:
定義位置
相關勾子
atom_enclosurerss2_nssites_clausesterms_clausescomment_closed
相關方法
rss_enclosureatom_enclosuredo_enclosedo_all_enclosuresget_enclosedrest_is_field_included
引入
2.2.0
棄用
-

rss_enclosure: 這個鉤子在RSS feed中被呼叫,以顯示每個專案的外殼資訊。外殼資訊用於指定附件,如Feed中的一個專案的媒體檔案。該鉤子可用於修改每個專案的外殼資訊。

過濾當前文章的RSS外殼的HTML連結標籤。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
echo apply_filters( 'rss_enclosure', '<enclosure url="' . esc_url( trim( $enclosure[0] ) ) . '" length="' . absint( trim( $enclosure[1] ) ) . '" type="' . esc_attr( $type ) . '" />' . "n" );
echo apply_filters( 'rss_enclosure', '<enclosure url="' . esc_url( trim( $enclosure[0] ) ) . '" length="' . absint( trim( $enclosure[1] ) ) . '" type="' . esc_attr( $type ) . '" />' . "n" );
echo apply_filters( 'rss_enclosure', '<enclosure url="' . esc_url( trim( $enclosure[0] ) ) . '" length="' . absint( trim( $enclosure[1] ) ) . '" type="' . esc_attr( $type ) . '" />' . "n" );

常見問題

FAQs
檢視更多 >