twentytwelve_attachment_size

過濾鉤子
apply_filters( 'twentytwelve_attachment_size', array( 960, 960 )
引數
  • (array) $size { @type int The attachment height in pixels. @type int The attachment width in pixels. }
    Required:
定義位置
  • wp-content/themes/twentytwelve/image.php , line 105
相關勾子
twentyeleven_attachment_sizetwentyten_attachment_sizetwentysixteen_attachment_sizetwentyfifteen_attachment_sizetwentyfourteen_attachment_size
相關方法
get_the_attachment_linkwp_delete_attachment_fileswp_get_attachment_image_sizeswp_get_attachment_imageget_attachment_linkget_attachment_icon
引入
Twenty Twelve 1.0
棄用
-

twentytwelve_attachment_size: 這個函式為”Twenty Twelve”WordPress主題設定附加圖片的大小。使用者可以通過修改該函式來改變附件圖片的大小。

過濾要使用的影象附件大小。

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

常見問題

FAQs
檢視更多 >