downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

HttpResponse::setCacheControl> <HttpResponse::setBufferSize
[edit] Last updated: Sat, 25 May 2013

view this page in

HttpResponse::setCache

(PECL pecl_http >= 0.10.0)

HttpResponse::setCacheSet cache

说明

static bool HttpResponse::setCache ( bool $cache )

Whether it should be attempted to cache the entity.

This will result in necessary caching headers and checks of clients If-Modified-Since and If-None-Match headers. If one of those headers matches a 304 Not Modified status code will be issued.

Note:

If you're using sessions, be sure that you set session.cache_limiter to something more appropriate than "no-cache"!

参数

cache

whether caching should be attempted

返回值

成功时返回 TRUE, 或者在失败时返回 FALSE

参见



add a note add a note User Contributed Notes HttpResponse::setCache - [0 notes]
There are no user contributed notes for this page.

 
show source | credits | sitemap | contact | advertising | mirror sites