Methods for caching PHP objects to file?

后端 未结 8 971
时光取名叫无心
时光取名叫无心 2020-12-24 12:42

In ASPNET, I grew to love the Application and Cache stores. They\'re awesome. For the uninitiated, you can just throw your data-logic objects into them, and hey-presto, you

8条回答
  •  Happy的楠姐
    2020-12-24 13:21

    You don't spell out -why- you're trying to cache objects. Are you trying to speed up a slow database query, work around expensive object instantiation, avoid repeated generation of complex page, maintain application state or are you just compulsively storing away objects in case of a long winter?

    The best solution, given the atrocious limitations of most low-cost shared hosting, is going to depend on what you're trying to accomplish. Going for bottom of the barrel shared-hosting means you have to accept that you won't be working with the best tools. The numbers are hard to quantify, but there's a trade off between hosting costs, site performance & developer time (ie - fast, cheap or easy).

提交回复
热议问题