clean_attachment_cache()
clean_attachment_cache( int $id, bool $clean_terms = false )
将清除缓存中的附件。
Will clean the attachment in the cache.
说明(Description)
清除意味着从缓存中删除。(可选)将清除与附件ID关联的术语对象缓存。
如果$wp_suspend_cache_invalization不为空,则此函数将不运行。
参数(Parameters)
参数 | 类型 | 必填 | 说明 |
---|---|---|---|
$id | (int) | 必需 | 要清除的缓存中的附件ID。 |
$clean_terms | (bool) | 可选 | 是否清理术语缓存。 |
返回(Return)
无返回值
源码(Source)
更新版本 | 源码位置 | 使用 | 被使用 |
---|---|---|---|
3.0.0 | wp-includes/post.php:6719 | 1 function | 4 |
clean_attachment_cache() 为WP2原创文章,链接:https://www.wp2.cn/functions/clean_attachment_cache-2/