函数文档

wp_cache_set_terms_last_changed()

💡 云策文档标注

概述

wp_cache_set_terms_last_changed() 是一个 WordPress 缓存函数,用于设置 'terms' 缓存组的最后更改时间。它通过调用 wp_cache_set_last_changed() 实现,确保缓存失效机制正常工作。

关键要点

  • 函数作用:设置 'terms' 缓存组的最后更改时间,以触发缓存更新。
  • 实现方式:内部调用 wp_cache_set_last_changed('terms'),简化了针对特定缓存组的操作。
  • 引入版本:自 WordPress 5.0.0 起引入,是缓存管理的一部分。
  • 相关函数:与 clean_taxonomy_cache()、clean_object_term_cache() 等函数关联,用于清理术语相关缓存。

📄 原文内容

Sets the last changed time for the ‘terms’ cache group.

Source

function wp_cache_set_terms_last_changed() {
	wp_cache_set_last_changed( 'terms' );
}

Changelog

Version Description
5.0.0 Introduced.