clean_term_cache()
clean_term_cache( int|int[] $ids, string $taxonomy = ”, bool $clean_taxonomy = true )
将从缓存中删除所有术语ID。
Will remove all of the term ids from the cache.
参数(Parameters)
参数 | 类型 | 必填 | 说明 |
---|---|---|---|
$ids | (int | int[]) | 必需 | 单个或一组术语ID。 |
$taxonomy | (string) | 可选 | 分类蛞蝓。可以为空,在这种情况下,将使用传递的术语id的分类法。 |
$clean_taxonomy | (bool) | 可选 | 是清除分类范围内的缓存(true),还是仅清除单个术语对象缓存(false)。 |
返回(Return)
无返回值
源码(Source)
更新版本 | 源码位置 | 使用 | 被使用 |
---|---|---|---|
2.3.0 | wp-includes/taxonomy.php:3231 | 6 | 6 |
clean_term_cache() 为WP2原创文章,链接:https://www.wp2.cn/functions/clean_term_cache-2/