Linux 软件免费装
Banner图

WP Term Images

开发者 johnjamesjacoby
stuttter
更新时间 2026年9月17日 04:38
捐献地址: 去捐款
PHP版本: 6.4 及以上
WordPress版本: 7.1
版权: GPLv2 or later
版权网址: 版权信息

标签

image images taxonomy metadata term

下载

1.0.0 2.1.3 2.2.0 2.1.2

详情介绍:

Images for categories, tags, and other taxonomy terms WP Term Images allows users to assign images to any visible category, tag, or taxonomy term using the media library, providing a customized look for their taxonomies. Also checkout

安装:

常见问题:

Does this plugin depend on any others?

No. Not since WordPress 4.4.

Does this create new database tables?

No. There are no new database tables with this plugin.

Does this modify existing database tables?

No. All of WordPress's core database tables remain untouched.

How do I get the image for a term?

With WordPress's get_term_meta() function ` // image id is stored as term meta $image_id = get_term_meta( 7, 'image', true ); // image data stored in array, second argument is which image size to retrieve $image_data = wp_get_attachment_image_src( $image_id, 'full' ); // image url is the first item in the array (aka 0) $image = $image_data[0]; if ( ! empty( $image ) ) { echo ''; } ` The attachment ID is also exposed as the term's image metadata in the WordPress REST API. To keep it out of REST responses, return false from the wp_term_image_show_in_rest filter.

Can I limit the taxonomies that use term images?

Yes. Filter the visible taxonomies after discovery and return only the ones that should use the image interface: add_filter( 'wp_term_image_allowed_taxonomies', function( $taxonomies ) { return array( 'category', 'post_tag' ); } );

Where can I find documentation?

https://github.com/stuttter/wp-term-images/wiki

更新日志:

[2.2.0] - 2026-09-16 [2.1.3] - 2026-09-16 [2.1.2] - 2026-09-14 [2.1.1] - 2026-09-14 [2.1.0] - 2026-09-13 [2.0.0] - 2019-05-30 [1.0.0] - 2017-01-16 [0.3.1] - 2016-07-13 [0.3.0] - 2016-05-27 [0.2.0] - 2016-01-07 [0.1.0] - 2015-11-09