Sorry for that, but i really concluded with the decision that it's better to ask directly than browsing tons of pages in vain. I've already looked through enough resources, but haven't found a decent explanation that could fulfill my curiosity about simplest question. Assume there’s a URI located at – hhtp://example.com/example
(including php script, queries to the database). Let’s imagine I’ve loaded it in my browser, click some link and hit “back” to return to hhtp://example.com/example
As far as I can allow myself to understand about what happens behind the scene looks smth like this: After “back” been clicked there browser checks its cache specifically hhtp://example.com/example
which matches exactly to the requested file (after “back”) and finds out that it wasn’t changed within this short period of time since it was first time loaded and returns it from its cache.
Wait!!!! The file contains server side scripts, database queries and so forth. So it should again reach web server, request same data from mysql and output it in a file.
So what’s the best strategy to cache dynamic content preferably on client-side vs server-side? In which cases it makes useful to cache content at server-side, and what practice is the best?
Please can someone provide some resources covering this subject that can be conceived by such dumpers like my and refute or adjust the scheme above about what actually happens.
While browsing the issue i run into one service - http://gtmetrix.com/ I liked very much, There were smth mentioned about making ajax request cacheable – I may assume that it can be perfectly used for client-side caching of dynamic content retrieved from database. Can someone please acknowledge it or deprecate?