image_attachment_fields_to_save

函式
image_attachment_fields_to_save ( $post, $attachment )
引數
  • (array) $post The WP_Post attachment object converted to an array.
    Required:
  • (array) $attachment An array of attachment metadata.
    Required:
返回值
  • (array) Attachment post object converted to an array.
定義位置
相關方法
image_attachment_fields_to_editget_attachment_fields_to_editmedia_single_attachment_fields_to_editmedia_post_single_attachment_fields_to_editget_attachment_icon_src
引入
2.5.0
棄用
6.0.0

image_attachment_fields_to_save: 此函式用於儲存媒體庫中影象附件的編輯欄位。

用於過濾來自 media_upload_form_handler() 的輸入,如果沒有提供檔名,則從檔名中指定一個預設的 post_title。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
function image_attachment_fields_to_save( $post, $attachment ) {
_deprecated_function( __FUNCTION__, '6.0.0' );
return $post;
}
function image_attachment_fields_to_save( $post, $attachment ) { _deprecated_function( __FUNCTION__, '6.0.0' ); return $post; }
function image_attachment_fields_to_save( $post, $attachment ) {
	_deprecated_function( __FUNCTION__, '6.0.0' );

	return $post;
}

常見問題

FAQs
檢視更多 >