Hi, I stumbled upon some methods of caching for dynamic pages to cut down on processing time, and I've built my own caching system based on these ideas.
Basically, the script looks for a pre-written htm file in a cache directory; if none is found, it writes one out using output buffering and saves it. If one is found however, it will exit() with a file_get_contents() from the cached htm file.
So with all the data from my database (so far), this would result in 927 cached htm files, totaling around 6.3 MB, and would grow over time.
My question then is, which is a better method?
By using the cache, I'd reduce 3-4 queries to my database to about 1, only to compare the modified date of the htm file to my databse content. On the other hand, I have a big mess of htm files, not sure if this increases a seek time or something?