开发者

Difference between COOKIE and CLIENT scopes in ColdFusion?

开发者 https://www.devze.com 2023-02-24 15:10 出处:网络
I have been googling, but haven\'t found an answer. I understand pretty well what the cookie scope does in ColdFusion. But I\'m not 100% sure abou开发者_StackOverflow中文版t the purpose of the client

I have been googling, but haven't found an answer.

I understand pretty well what the cookie scope does in ColdFusion. But I'm not 100% sure abou开发者_StackOverflow中文版t the purpose of the client scope or the differences between it and the cookie scope. It gets a bit muddy because one of the storage methods for the client scope can be set to cookie.

Can someone supply an example, or use-case, that illustrates what the differences are and when I would use one versus the other?


Cookie scope persists the data as cookies on client's browser. Keep it small as it is sent along Every freaking http request. :)

Client scope can persist the data on DB (or registery on Windows, BAD BAD BAD, but it is the default). It is used often in a clustered env with non-sticky session, where a request might be routed to any server where Session data is not available.

I don't have the link, but you can read more on them in CF Dev Guide.

0

精彩评论

暂无评论...
验证码 换一张
取 消