Remove a file from cache

Hi dears,
I have customers.txt file which I modify via Ajax and php.
When I read it via readfile() it returns me the cached version.
Is there a way to access to file on server avoiding cached one?
Thanks in advance
Rotondi Alex

Try adding a random number to your readfile like this:

randomValue = SysInfo(10)
C = URLServer & β€œhttps://yourdomain.com/yourfolder/something.txt?” & randomValue
req=ReadFile(C)

John

Dear John,
thanks a lot, it works, and for me at present it’s sufficient to go on.
Anyway, is there a way to access cache files and remove them from the cache?

Alex

A couple of thoughts. You might look at this to use the CacheStorage API:

If security is your concern then you should consider encoding/encrypting the sensitive data.

John

1 Like

Thanks again it’s very good guide.
Mainly my problem is being able to always recover fresh data, because as a database, I use a system of files.txt (json strings) that I encrypt/decrypt with my own routine. But then I would like to learn how to use mysql well and anyway I am very interested in this cache topic.
Best regards
Alex