Welcome Guest, Not a member yet? Register   Sign In
Sharing the CI cache folder
#1

[eluser]Nial[/eluser]
Apologies if this has been asked before. I did a quick forum search and checked the documentation. Basically, I'm using CI with another third-party library that makes use of flat-file caching. To keep things clean, I have the library place its cached files into CI's default cache directory.

I just wanted to make sure that CI only flushes the cache files it creates. This seems like the logical behaviour. As far as I can tell, CI checks for timestamp metadata within its cache files. If it's not present, the cache is ignored.

Code:
if ( ! preg_match("/(\d+TS--->)/", $cache, $match))
        {
            return FALSE;
        }

It'd just be nice to get this confirmed.
#2

[eluser]Damien K.[/eluser]
Presumably, it matches a given pattern in the metadata. If your third-party library uses a similar pattern for their metadata, then no doubt CI will flush those out as well.

1) Identify if the metadata from CI and the third-party library has the same pattern
2) Read the source code for CI (not sure if the code you provided was from CI or not)




Theme © iAndrew 2016 - Forum software by © MyBB