⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 function.httpresponse-setcachecontrol.html

📁 php的帮助文档,涉及到PHP的案例和基本语法,以及实际应用内容
💻 HTML
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><html> <head>  <title>Set cache control</title>  <meta http-equiv="content-type" content="text/html; charset=UTF-8"> </head> <body><div style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.httpresponse-setcache.html">HttpResponse::setCache</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.httpresponse-setcontentdisposition.html">HttpResponse::setContentDisposition</a></div> <div class="up"><a href="class.httpresponse.html">The HttpResponse</a></div> <div class="home"><a href="index.html">PHP Manual</a></div></div><hr /><div id="function.httpresponse-setcachecontrol" class="refentry"> <div class="refnamediv">  <h1 class="refname">HttpResponse::setCacheControl</h1>  <p class="verinfo">(PECL pecl_http:0.10.0-1.5.5)</p><p class="refpurpose"><span class="refname">HttpResponse::setCacheControl</span> &mdash; <span class="dc-title">Set cache control</span></p> </div> <div class="refsect1 description">  <h3 class="title">Description</h3>  <div class="methodsynopsis dc-description">   <span class="modifier">static</span>   <span class="type">bool</span> <span class="methodname"><b><b>HttpResponse::setCacheControl</b></b></span>    ( <span class="methodparam"><span class="type">string</span> <tt class="parameter">$control</tt></span>   [, <span class="methodparam"><span class="type">int</span> <tt class="parameter">$max_age = 0</tt></span>   [, <span class="methodparam"><span class="type">bool</span> <tt class="parameter">$must_revalidate = TRUE</tt></span>  ]] )</div>  <p class="para rdfs-comment">   Define a custom <i>Cache-Control</i> header, usually being <em class="emphasis">private</em> or <em class="emphasis">public</em>;  </p> </div> <div class="refsect1 parameters">  <h3 class="title">Parameters</h3>  <p class="para">   <dl>    <dt>     <span class="term"><i><tt class="parameter">control</tt></i></span>     <dd>      <p class="para">       the primary cache control setting      </p>     </dd>    </dt>    <dt>     <span class="term"><i><tt class="parameter">max_age</tt></i></span>     <dd>      <p class="para">       the max-age in seconds, suggesting how long the cache entry is valid on the client side      </p>     </dd>    </dt>    <dt>     <span class="term"><i><tt class="parameter">must_revalidate</tt></i></span>     <dd>      <p class="para">       whether the cached entity should be revalidated by the client for every request      </p>     </dd>    </dt>   </dl>  </p> </div> <div class="refsect1 returnvalues">  <h3 class="title">Return Values</h3>  <p class="para">   Returns <b><tt>TRUE</tt></b> on success, or <b><tt>FALSE</tt></b> if control does not match one of <em class="emphasis">public</em>, <em class="emphasis">private</em> or <em class="emphasis">no-cache</em>.  </p> </div>   <div class="refsect1 seealso">  <h3 class="title">See Also</h3>  <p class="para">   <ul class="simplelist">    <li class="member"><a href="function.httpresponse-getcachecontrol.html" class="function" rel="rdfs-seeAlso">HttpResponse::getCacheControl()</a></li>    <li class="member"><a href="function.httpresponse-setcache.html" class="function" rel="rdfs-seeAlso">HttpResponse::setCache()</a></li>    <li class="member"><a href="function.httpresponse-getcache.html" class="function" rel="rdfs-seeAlso">HttpResponse::getCache()</a></li>   </ul>  </p> </div></div><hr /><div style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.httpresponse-setcache.html">HttpResponse::setCache</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.httpresponse-setcontentdisposition.html">HttpResponse::setContentDisposition</a></div> <div class="up"><a href="class.httpresponse.html">The HttpResponse</a></div> <div class="home"><a href="index.html">PHP Manual</a></div></div></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -