Opens in a new tab
A picture of Jeff Brigman
I CODE TODAY FOR
A BETTER TOMORROW

Glossary Term

clearstatcache()

3 tags 1 category

clearstatcache() — Clears file status cache.

When you use stat, lstat, or any of the other functions listed in the affected functions list (below), PHP caches the information those functions return in order to provide faster performance. However, in certain cases, you may want to clear the cached information. For instance, if the same file is being checked multiple times within a single script, and that file is in danger of being removed or changed during that script’s operation, you may elect to clear the status cache. In these cases, you can use the clearstatcache function to clear the information that PHP caches about a file.

Inputs: clear_realpath_cache: Whether to also clear the realpath cache. filename: Clear the realpath cache for a specific filename only; only used if clear_realpath_cache is true.

Returns: No value is returned.

Term Connections

Explore related terms connected by shared tags, shared categories, and relationship phrases. This map loads only when it comes into view.

Loading term connections…