F
F
fashionmens2019-04-18 12:19:54
caching
fashionmens, 2019-04-18 12:19:54

Why is Laravel not saving cache? Only within one request?

Cache::put('cats', 'TEST', 60);
dump(Cache::has('cats'));
This code shows true. Everything is fine here.
But when I run the same site on another page - dump(Cache::has('cats'));
Writes - false
That is, the cache is saved only within the framework of one request. How can this be.
I didn't touch the cache settings. Files in /storage/framework/cache/ are created.
Laravel version - 5.2.45

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question