[thelist] Caching: PHP or Clientside?

Ken Schaefer ken.schaefer at gmail.com
Thu Sep 23 00:42:10 CDT 2004

Hmm - I would ask what you are seeking to achieve by caching this
particular piece of data.

For example, if it's something from datastore (and you are caching it
so as to avoid hitting the datastore over and over again), then you
could cache this server-side.

On the other hand, if this is some data that you don't want the client
to download over and over again, then you'd need to somehow cache this
on the client.

Caching something in a cookie doesn't sound like a good idea to me -
the cookie is going to be returned by the client to the server (and
then by the server to the client) on each request, adding to the time
it takes for each page to load...


On Thu, 23 Sep 2004 00:59:46 -0400, Mr. Tenuta <dtportnoy at videotron.ca> wrote:
> I'm caching a huge chunk of html output and am debating where to put it. Would it be efficient to store that code in a PHP variable and carry that variable throughout every page?
> Should I store it clientside? If so how do I store all that data? In a cookie?
> PHP variable or Clientside? which would be more efficient. I'm just not sure if it's bad programming carrying a bunch of output from page to page. (of course with sessions)

More information about the thelist mailing list