Camen Design Forum

Delete

(Leave this as-is, it’s a trap!)

To delete this post you must be either the original author or a designated moderator.
The content of the post will be removed but the name and date will remain.

  • The post will be removed completely from the thread, rather than blanked
  • Only posts on the last page of the thread can be removed completely (so as to not break permalinks)

RE: PHP and filesystem efficiency?

Johann

"BTW, if you're caching POST requests, wouldn't you have to throw the entire raw request body into the hash?"

Well yeah, that is, I just json_encode() the $_POST array and append that to the input for the hash. It's a bit overkill because it only ever ends up being used for the search, but it's the only way I could see to allow for that.

"Part of the reason I'm caching pages is so I don't have to access a DB at all."

Sure, but in my case the startup time (include() and init) comes close to the cost of the MySQL connection, so I figured to not care about those 10-15 miliseconds and enjoy all the convenience doing that in the database offers :)

Not to hijack the thread though (at least not until your question has been answered :D)

Your friendly neighbourhood moderators: Kroc, Impressed, Martijn